def manhattan_dist_4d(p1, p2):
    """
    Compute manhattan distance between 4D points p1 and p2
    """
    dist = 0
    for axis in range(4):
        dist += abs(p2[axis] - p1[axis])

    return dist