100 atcoder#ABC097B. [ABC097B] Exponential
[ABC097B] Exponential
Score : points
Problem Statement
You are given a positive integer . Find the largest perfect power that is at most . Here, a perfect power is an integer that can be represented as , where is an integer not less than and is an integer not less than .
Constraints
- is an integer.
Input
Input is given from Standard Input in the following format:
Output
Print the largest perfect power that is at most .
10
9
There are four perfect powers that are at most : , , and . We should print the largest among them, .
1
1
999
961