Regarding algorithm used in travelling salemans problem

can’t we use floyd warshall algorithm to solve this problem???

@souravkhanna227, the problem with floyd warshal is tha it can give you the minimum distance between two nodes in o(1) after precomputation , but it does’nt tell you how many and which intermediate nodes it has taken into consideration,so with floyd warshal you can’t maintain the condition of tsp problem that the salesman visit every node only once