import math r, d = map(float, input().split()) length = math.sqrt(d**2 - r**2) print("{0:.12f}".format(length))