#1072
Unrated
REZ
스페셜 저지채점 준비중
시간 제한
1s
메모리 제한
32MB
제출
0
정답
0
맞힌 사람
0
정답 비율
0.0%

문제

Author: Anton Grbin

Let‟s say that there exists a huge cake made from blueberries, strawberries and chocolate. It‟s shaped like a square, and has area of 100 square meters. Proffesionals strongly advise that cake is being cut with wet knife and eaten with dry spoon. Also:  Every cut begins and ends on the cake‟s perimeter  A cut cannot lie completely on one of the sides  No two cuts have the same starting and ending points, i.e. all cuts are different Parts obtained by these cuts are separated and counted only after last cut has been made. During cutting, the cake keeps its square form. At least how many cuts need to be made in order to obtain at least K parts? Exactly what cuts to make?

입력

The first and only line of input contains an integer K (1 ≤ K ≤ 1 000 000), minimum number of parts that we must have after cutting is done.

출력

The first line of output should contain the requested number of cuts, N. The following N lines should have four integers each, coordinates of starting and ending point for each cut made. Coordinates are represented in millimeters, and opposing corners of the cake have coordinates (-5000, -5000) and (5000, 5000). So for each point (x, y) lying on the side of the square, the following will hold: max( |x|, |y| ) = 5000.

예제 입력 1

1

예제 출력 1

0

예제 입력 2

4

예제 출력 2

2
-5000 -5000 5000 5000
5000 -5000 -5000 5000

예제 입력 3

7

예제 출력 3

3
-5000 5000 0 -5000
0 -5000 5000 5000
-5000 0 5000 0
코드 제출

이 문제는 현재 제출할 수 없습니다.

이 현상이 잘못되었다고 생각될 경우 관리자한테 문의주세요.

내 제출
제출 내역이 없습니다.
맞은 사람
아직 맞은 사람이 없습니다.
난이도 투표
Unrated0명 투표
로그인 후 AC 받으면 투표할 수 있습니다.
전체 제출
제출 내역이 없습니다.