#include using namespace std; using ll = long long; #define fi first #define se second #define all(a) a.begin(),a.end() int main(){ int x,y; cin >> x >> y; double i=0,r=sqrt(x*x+y*y); while(i<=r) i+=0.5; cout << 2*i << endl; return 0; }