시간 제한 메모리 제한 제출 정답 맞은 사람 정답 비율
1 초 128 MB 956 750 717 79.314%

문제

2차원 좌표 상의 여러 점의 좌표 (x,y)가 주어졌을 때, 각 사분면과 축에 점이 몇 개 있는지 구하는 프로그램을 작성하시오.

입력

첫째 줄에 점의 개수 n (1 ≤ n ≤ 1000)이 주어진다. 다음 n개 줄에는 점의 좌표 (xi, yi)가 주어진다. (-106 ≤ xi, yi ≤ 106)

출력

각 사분면과 축에 점이 몇 개 있는지를 예제 출력과 같은 형식으로 출력한다.

예제 입력 1

5
0 0
0 1
1 1
3 -3
2 2


예제 출력 1

Q1: 2
Q2: 0
Q3: 0
Q4: 1
AXIS: 2


힌트

W3sicHJvYmxlbV9pZCI6Ijk2MTAiLCJwcm9ibGVtX2xhbmciOiIwIiwidGl0bGUiOiJcdWMwYWNcdWJkODRcdWJhNzQiLCJkZXNjcmlwdGlvbiI6IjxwPjJcdWNjMjhcdWM2ZDAgXHVjODhjXHVkNDVjIFx1YzBjMVx1Yzc1OCBcdWM1ZWNcdWI3ZWMgXHVjODEwXHVjNzU4IFx1Yzg4Y1x1ZDQ1YyAoeCx5KVx1YWMwMCBcdWM4ZmNcdWM1YjRcdWM4NGNcdWM3NDQgXHViNTRjLCBcdWFjMDEgXHVjMGFjXHViZDg0XHViYTc0XHVhY2ZjIFx1Y2Q5NVx1YzVkMCBcdWM4MTBcdWM3NzQgXHViYTg3IFx1YWMxYyBcdWM3ODhcdWIyOTRcdWM5YzAgXHVhZDZjXHVkNTU4XHViMjk0IFx1ZDUwNFx1Yjg1Y1x1YWRmOFx1YjdhOFx1Yzc0NCBcdWM3OTFcdWMxMzFcdWQ1NThcdWMyZGNcdWM2MjQuPFwvcD5cclxuXHJcbjxwPjxpbWcgYWx0PVwiXCIgc3JjPVwiXC91cGxvYWRcL2ltYWdlc1wvcXVhZC5wbmdcIiBzdHlsZT1cImhlaWdodDoxOTBweDsgd2lkdGg6MjkycHhcIiBcLz48XC9wPlxyXG4iLCJpbnB1d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