A,B,C=map(int,input().split()) p=[abs(A-B),abs(B-C),abs(C-A)] print(min(p))