#yuki_419 import math a,b=map(int,raw_input().split()) if a==b: print math.sqrt(a**2+b**2) else: print math.sqrt(abs(a**2-b**2))