300528: CF100I. Rotation
Memory Limit:64 MB
Time Limit:2 S
Judge Style:Text Compare
Creator:
Submit:0
Solved:0
Description
I. Rotationtime limit per test2 secondsmemory limit per test64 megabytesinputstandard inputoutputstandard output
Ehsan loves geometry! Especially he likes to rotate points!
Given a point in the plane, Ehsan likes to rotate it by k degrees (counter-clockwise), around the origin. What is the result of this rotation?
InputA single integer k (0 ≤ k < 360) is given in the first line. Two integer numbers x and y are given in the second line ( - 1390 ≤ x, y ≤ 1390).
OutputWrite two numbers. The result of the rotation. Your answer must have a relative error less than 10 - 1.
ExamplesInput90Output
1 1
-1.00000000 1.00000000Input
180Output
1 1390
-1.00000000 -1390.00000000