3 ms·
> You should not be blamed for assuming, when talking to Google, that the O(n!) or O(n^2) solution is not even worth talking about. If the naive solution is O(
by davidcbc 8y ago
> You should not be blamed for assuming, when talking to Google, that the O(n!) or O(n^2) solution is not even worth talking about.
If the naive solution is O(n!) then describing an O(n^2) solution is perfectly acceptable.
- zodiac 8y agoInteresting fact: the standard DP algorithm for TSP reduces the running time from O(n!) to O(n^2 2^n)