#include < bits / stdc++.h > using namespace std;
typedef long long ll;
const int N = 1e5 + 10;
ll hh(ll x, ll y) {
ll s = 1;
while (y) {
if (y & 1) s = s * x;
x *= x;
y >>= 1;
}
return s;
}
ll a[20];
int main() {
ll n;
for (ll i = 1; i <= 15; i++) {
a[i] = hh(i, i);
}
while (~scanf("%lld", &n)) {
int t = 0,
y;
for (int i = 1; i <= 15; i++) {
if (a[i] > n) {
t = 1;
y = i - 1;
break;
}
}
if (t) {
printf("%d\n", y);
} else printf("%d\n", 15);
}
return 0;
}
来源: http://www.bubuko.com/infodetail-2285698.html