a,b=map(int,input().split()) ans=(a-b)**3/6 if ans<0: ans=-ans print(ans)