eolymp
bolt
Try our new interface for solving problems
Problems

Unexpressed

Unexpressed

One integer $n$ is given. How many integers between $1$ and $n$ (inclusive) are unrepresentable as $a^b$, where $a$ and $b$ are integers not less than $2$? \InputFile One positive integer $n~(n \le 10^{10})$. \OutputFile Print the amount of unrepresentable numbers.
Time limit 1 second
Memory limit 128 MiB
Input example #1
8
Output example #1
6
Input example #2
100000
Output example #2
99634