a,b,c = map(int, input().split()) print(min(map(abs,[a-b,b-c,c-a])))