(name, x, y) tuples. Write nearest_hub(hubs, px, py) returning the name of the hub closest to the point (px, py) by straight-line distance, using min with a lambda key. No need to take a square root — comparing squared distances gives the same winner.nearest_hub([('North', 0, 5), ('East', 2, 1)], 0, 0)'East'
East is √5 away; North is 5 away.
Squared distance: (x-px)**2 + (y-py)**2.
Read [0] off the winning tuple.