from math import*

def Heron(a,p):
    u=1
    v=(u+a/u)/2
    while abs(v-u)     :
        u=v
        v=(u+a/u)/2
    return ...

