410503: GYM104030 D Disc District

Memory Limit:512 MB Time Limit:1 S
Judge Style:Text Compare Creator:
Submit:0 Solved:0

Description

D. Disc Districttime limit per test1 secondmemory limit per test512 megabytesinputstandard inputoutputstandard output

You live in the Disc District of Flatland and work for the Nearest Convenient Plot Company (NCPC). Your job is to find the nearest convenient plot of land outside of the Disc District to build on.

The Disc District can be described as a disc on a plane with center $$$(0, 0)$$$ and some radius $$$r$$$. So a point is outside of the Disc District if the (Euclidean) distance from it to the origin is strictly larger than $$$r$$$. A point $$$(x, y)$$$ on the plane is a convenient plot if $$$x$$$ and $$$y$$$ are integers.

Input

The only line of the input contains a single integer $$$r$$$ ($$$1 \leq r \leq 10^6$$$).

Output

The output should contain a single line with two integers, the $$$x$$$ and $$$y$$$ coordinates of a convenient building location that is closest to the Disc District. If there are more than one answer, output any of them.

ExamplesInput
1
Output
1 1
Input
8
Output
4 7
Input
90210
Output
69551 57450

加入题单

上一题 下一题 算法标签: