Save up to $499! Grab all Python courses for $49 or all online courses we’ve ever launched for only $169. Only Feb 11-16. Happy Valentine's!
Introduction
The very basics
Infinite looping
Processing graphs with recursive CTE
30. Traveling salesman - exercise 2
Summary

Instruction

That's it! One more exercise based on that example.

Exercise

Bristol turned out to be a horrible location - it was too far away from London. Instead, the management decided to split the headquarters into three smaller offices: one in London, and the other two in two other cities.

Produce paths starting in London as before, but they should now consist of 3 cities only (London and two other cities). Sort the paths by the descending total_distance so that the management can decide where to place the offices.

Stuck? Here's a hint!

You only need to modify the outer query a bit!