a, b = [int(x) for x in input().split()] ans = 1 / 6 * (b - a) ** 3 print(ans)