题面
python 大法好
直接二分即可
注意向下取整1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17m = int(input())
n = int(input())
l = 0
r = 1
while(r ** m <= n):
l = r
r = r * 2
while(l + 1 < r):
mid = (l + r) // 2
if (mid ** m <= n):
l = mid
else:
r = mid
if (l ** m <= n):
print(l)
else:
print(r)