import math a, b = map(int, input().split()) if a < b: a, b = b, a print(min(math.sqrt(a * a - b * b), math.sqrt(a * a + b * b)))