00:01
Okay, this question asks us about the traveling salesman problem, where the first part says a salesman wants to visit ten cities.
00:10
How many different ways are possible? well, he's going between ten different cities, so he has ten cities to start from, and then he has nine choices to go through, go to from there, then eight, then seven, then six, then five, then four, then three, then two, then one.
00:39
So there are 10 factorial different circuits he could check and that evaluates to 362 -880 for the total number of circuits.
00:56
But we can actually save some computation time here before we're to check all these because the path won't depend on what order we go in.
01:09
Because if you take the same route when you go to the store, as you do when you come home from the store, you go to the store, you go to the store, you go to the the same distance.
01:17
So for every route in part a, there's actually two identical routes, because there's the forward path and the backward path.
01:30
So it's just the number of paths in part a divided by two, because we want to get rid of all the permutations that are just the same thing in the reverse order...