WA on SPOJ TOURS

Revision en1, by raj_meena, 2015-11-12 20:09:13

http://www.spoj.com/problems/TOURS/ Above is problem link. My approach is follow :

1. Find All Pairs Shortest paths
2. Create Flow Network where flow will be 1 and cost will be distance from i to j.
3. Add Super Source and Super Sink then Using mincostmaxflow find minimum cost print it.

Any Hint?? , Test case, your approach anything all are welcome :D :)

Sorry for my poor english

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en1 English raj_meena 2015-11-12 20:09:13 431 Initial revision (published)