Problem: Pak Chanek plans to build a garage. He wants the garage to consist of a square and a right triangle that are arranged like the following illustration.
Define and as the lengths of two of the sides in the right triangle as shown in the illustration. An integer is suitable if and only if we can construct a garage with assigning positive integer values for the lengths and () so that the area of the square at the bottom is exactly . As a good friend of Pak Chanek, you are asked to help him find the -th smallest suitable number.
Input Format: The only line contains a single integer ().
Output Format: An integer that represents the -th smallest suitable number.
Note: The -rd smallest suitable number is . A square area of can be obtained by assigning and .