The travelling salesman problem (TSP) asks the following question: "Given a list of cities and the distances between each pair of cities, what is the shortest possible route that visits each city exactly once and returns to the origin city?" In this notebook, I demonstate the solution of this problem with the genetic algorithm.
The origin and destination cities are the same:
The origin and destination cities are different ones: