#include #include using namespace std; using namespace atcoder; using ll=long long; using ld=long double; ld pie=3.141592653589793; ll inf=144494; ll mod=1000000007; int main(){ ld ans=4.0*pie; ld a,b; cin >> a >> b; if (a>b) { swap(a,b); } if (a>=0) { ans-=2.0*pie; ans-=2.0*pie*(1.0-a); ld x=2.0*pie; x-=ans; x-=2.0*pie*(1.0-b); cout << setprecision(100) << x << endl; }else{ if (b<=0) { ans-=2.0*pie; ans-=2.0*pie*(1.0+b); ld x=2.0*pie; x-=ans; x-=2.0*pie*(1.0+a); cout << setprecision(100) << x << endl; }else{ ans-=2.0*(1.0+a)*pie; ans-=2.0*(1.0-b)*pie; cout << setprecision(100) << ans << endl; } } }