import math


def get_coord_distance(c1, c2):
    """
    Coordinates c1 and c2 are tuples of (x, y) or (longitude, lattitude)  
    """
    #print(c1, c2) 
    R = 6371000  # Radius of the earth in meters
    lat1 = math.radians(c1[1])
    lat2 = math.radians(c2[1])

    lon1 = math.radians(c1[0])
    lon2 = math.radians(c2[0]) 
    
    dlat = lat2 - lat1 
    dlon = lon2 - lon1 
    a = math.sin(dlat/2)**2 + math.cos(lat1) * math.cos(lat2) * \
            math.sin(dlon/2)**2
    
    c = 2 * math.asin(math.sqrt(a)) 

    return c * R