#arc135a. [arc135_a]Floor, Ceil - Decomposition
[arc135_a]Floor, Ceil - Decomposition
Problem Statement
There is an integer written on a blackboard. You can do the operation below any number of times (possibly zero).
- Choose an integer written on the blackboard.
- Erase one from the blackboard and write two new integers and .
Find the maximum possible product of the integers on the blackboard after your operations, modulo .
What are and ?
For a real number , denotes the largest integer not greater than , and denotes the smallest integer not less than . For example, the following holds.
- For , we have and .
- For , we have , .
Constraints
Input
Input is given from Standard Input from the following format:
Output
Print the maximum possible product of the integers on the blackboard after your operations, modulo .
Sample Input 1
15
Sample Output 1
192
Here is a sequence of operations that makes the product of the integers on the blackboard .
- The initial state of the blackboard is .
- An operation with changes it to .
- An operation with changes it to .
- An operation with changes it to .
- An operation with changes it to .
Here, the product of the integers on the blackboard is .
Sample Input 2
3
Sample Output 2
3
Doing zero operations makes the product of the integers on the blackboard .
Sample Input 3
100
Sample Output 3
824552442
The maximum possible product of the integers on the blackboard after your operations is , which should be printed modulo .