import math l,m=map(int,input().split()) l,m=max(l,m),min(l,m) if l==m: s = l**2 + m**2 else: s = l**2 - m**2 print(math.sqrt(s))