def pierwiastek(x, eps):
a = 0
b = x
while abs(b - a) > eps:
c= (a + b) / 2
if c * c > x:
b = c
else :
a = c
return c
print(pierwiastek(4,1))
ZGVmIHBpZXJ3aWFzdGVrKHgsIGVwcyk6CglhID0gMAoJYiA9IHgKCXdoaWxlIGFicyhiIC0gYSkgPiBlcHM6CgkJYz0gKGEgKyBiKSAvIDIKCQlpZiBjICogYyA+IHg6CgkJCQliID0gYwoJCWVsc2UgOgoJCQlhID0gYwoJcmV0dXJuIGMKcHJpbnQocGllcndpYXN0ZWsoNCwxKSk=