#include <iostream>
using namespace std;
int main() {
long long x, y, s = 0, max = 0, i1 = 0;
int r;
cin >> r;
for (int i = 1; i <= r; ++i) {
s = 0;
for (x = -i - 1; x <= i; ++x)
for (y = -i - 1; y <= i; ++y)
if (x*x + y * y == i * i) ++s;
if (max < s) { max = s; i1 = i; }
}
cout << i1;
return 0;
}