Tuple unpacking and the mapping problem.
I'm stuck on the problem that has to do with tuple unpacking with mapping software. I am asked to output the shortest distance from the point (0, 0) out of a list of points. The code I have feels right but the test case says it is wrong and the test case is hidden so I have no idea if I'm close or if it is problem with the final number not being rounded. Can anybody tell me where I am doing wrong? Here's my code. import math # Calculate and output the distance to the closest point from # the point (0, 0) points = [ (12, 55), (880, 123), (64, 64), (190, 1024), (77, 33), (42, 11), (0, 90) ] distances = [] for (x, y) in points: z = math.sqrt((x ** 2) + ( y ** 2)) distances.append([z]) print(min(distances))