def euclidean_dist(p1, p2):
    """
    Returns the euclidean distance between points (p1, p2)
    in n-dimensional space.

    Points must have the same number of dimensions.
    """
    if len(p1) != len(p2):
        raise ValueError("Points must have the same number of dimensions.")
    return sum((d1 - d2) ** 2 for d1, d2 in zip(p1, p2)) ** 0.5