#P9502. 『MGOI』Simple Round I | A. 魔法数字
『MGOI』Simple Round I | A. 魔法数字
Background
The more determined a mage is, the luckier they are. — Hall Mage S.
Problem Description
The magic number of the junior mage Xiao M is .
Given a positive integer , Xiao M needs to find the largest even integer such that .
Please help him.
Input Format
One line containing one positive integer .
Output Format
One line containing one even integer , which is the answer.
7
2
8
2
1024
8
Hint
Constraints
For the first of the testdata, .
For the first of the testdata, is a power of .
For of the testdata, .
Translated by ChatGPT 5