#include #include #include #include #include #include #include #include #include #include using namespace std; int main(){ int a, b, c; cin >> a >> b >> c; cout << min({abs(abs(b - a) - abs(b - c)), abs(b-a), abs (b-c)}) << endl; }