import math a,b = map(int,input().split()) a,b = min(a,b),max(a,b) if a == b: c = b * b + a * a else: c = b * b - a * a print('%.09f' % math.sqrt(c))