def seuil():
    n = 0
    r = 1
    while abs( r - sqrt(2) ) > 10**(-4):
        r = (2 + r) / (1 + r)
        n = n + 1
    return n
