atcoder#ABC246D. [ABC246D] 2-variable Function
[ABC246D] 2-variable Function
Score : points
Problem Statement
Given an integer , find the smallest integer that satisfies all of the conditions below.
- is greater than or equal to .
- There is a pair of non-negative integers such that .
Constraints
- is an integer.
Input
Input is given from Standard Input in the following format:
Output
Print the answer as an integer.
9
15
For any integer such that , there is no that satisfies the condition in the statement. For , satisfies the condition.
0
0
itself may satisfy the condition.
999999999989449206
1000000000000000000
Input and output may not fit into a -bit integer type.