#include #include using namespace std; int main() { long long int b; long long int ac[2]; cin >> ac[0] >> b >> ac[1]; long long int ans = min(abs(ac[0] - b),min(abs(ac[0] - ac[1]),abs(ac[1] -b))); cout << ans; return 0; }