PivotOJ

Arm Coordination

시간 제한: 2000ms메모리 제한: 1024MB출처: BAPC 2021BOJ 23375

문제

All the cool kids in town want to become a member of the Bots and Androids Programmer Club (BAPC). To become a member of the club, applicants must show a feat of their skills with a home-made robot that is programmed to perform some tricks. Just like your older brother, you want to become a member of the BAPC, so it's time to lock yourself in the hobby basement and start building some robots!

Since your older brother has used up almost all of the parts for his own projects at the BAPC, you will have to get creative with whatever is still left. You find a robotic arm that has only a single purpose: fitting circle-shaped objects into square-shaped holes. Not exactly what you had in mind, but it will have to do. After all, you only have five hours left to apply for your BAPC membership.

The memory chip of the robotic arm seems to be wiped, but luckily you do know the programming interface of its ARM processor. Firstly, the robotic arm only supports integer coordinates. Secondly, when the arm picks up a circle-shaped object, you need to calculate the smallest possible square that it could fit the object in, after which it will autonomically find a suitable square-shaped hole.

Given the location of a circle-shaped object, calculate the smallest possible square which encloses the object.

입력

The input consists of:

  • One line containing two integers xx and yy (109x,y109-10^9\leq x,y\leq 10^9), the coordinates of the center of the circle.
  • One line containing one integer rr (1r1091\leq r\leq 10^9), the radius of the circle.

출력

Output four lines, each line containing two integers, representing the xx- and yy-coordinates of one of the corners of the square. The coordinates should be printed in either clockwise or counter-clockwise order.

If there are multiple valid solutions, you may output any one of them.

예제

예제 1

입력
-3 6
5
출력
-10 7
-2 13
4 5
-4 -1

예제 2

입력
0 0
10
출력
-14 -2
-2 14
14 2
2 -14
이 문제는 채점 준비 중입니다. 테스트 데이터가 확보되면 제출이 가능합니다.