def distance(x1,x2,y1,y2): # A squared + B squared = C squared return ( ( (x2 - x1)**2) + ( (y2-y1)**2) )**.5 # Object 1 Location coordinate1 = 2,8 # x,y # Object 2 Location coordinate2 = 5,10 # x,y print (distance(coordinate1[0],coordinate2[0],coordinate1[1],coordinate2[1]))

Thanks.