People don't know how to solve this problem faster than testing every possible answer, but if a solution is found that allows the salesman to do this, we can use an algorithm check that it is true. This problem is also known as Travelling salesman problem.