Get your own website
Python
C
Java
 
Python result:
C result:
Java result:
Route: [0, 1, 2, 5, 3, 4, 0]
Total distance: 31
Route: 0 1 2 5 3 4 0
Total Distance: 31
Route: 0 1 2 5 3 4 0
Total Distance: 31