def in_close(x,l, epsilon=0.0001):
    """
    returns true if x lies within epsilon of some element in the list l, otherwise false
    """
    for i in l:
        if abs(x-i)<epsilon:
            return True
    return False