시간 제한 메모리 제한 제출 정답 맞은 사람 정답 비율
1 초 128 MB 86 22 18 31.034%

문제

택희는 OS조교이다. 이번 숙제는 간단히 pintos가 동작하는 화면을 캡쳐한 다음에, 이를 프린트해서 제출하는 것이다. 학생들은 보고서에 자기 학번, 이름과 제출한 날짜를 간단하게히 써서 내면 된다. 어차피 올해가 몇 년인지는 모두가 알고 있기 때문에, 월/일만 적어서 내면 된다. 예를 들어, 09/20/2005 (2005년 9월 20일)이라고 쓰는 대신에 9/20이라고 쓰면 된다.

일단 채점하기 전에 과거 채점 기준을 확인하기 위해서 예전에 사람들이 냈던 보고서와 점수를 확인하고 있었다. 그런데... 올해 숙제와 예전 숙제가 섞이고 말았다. 학생들이 보고서에 연도를 쓰지 않았고, 보고서에 채점 결과를 써놓지 않았기 때문에, 보고서만 가지고는 언제 숙제인지 알수가 없게 되었다. 게다가 숙제 마감일은 매년 같다.

따라서 택희는 제출일과 숙제 마감일을 가지고 채점을 해야할지 말아야할지 결정하려고 한다.

숙제 마감일과 각 학생이 제출한 날짜가 주어졌을 때, 이것을 채점해야할지 말아야할지, 결정하는 프로그램을 작성하시오. 출력에 대한 설명은 출력 설명에 자세히 나와있다.

입력

첫째 줄에 테스트 케이스의 개수 T가 주어진다. 둘째줄부터 T개의 줄에는 각 테스트 케이스의 정보가 주어진다. 테스트 케이스의 정보는 날짜 2개로 이루어져 있다. 첫 번째 날짜는 숙제 마감일이고, 두 번째 날짜는 보고서에 적힌 날짜이다. 숙제 마감일은 월/일/연 형식이다. 숙제마감일은 2000년이상, 2200년 이하이고, 올바른 날짜만 주어진다.  보고서에 적힌 날짜는 월/일 형식이고, 이 날짜도 올바른 날짜만 주어진다.

출력

각 테스트 케이스에 대해서 다음과 같이 출력한다.

m/d/y IS n DAY(S) PRIOR: 보고서에 적힌 날짜가 숙제 마감일보다 7일전 이내 일 때 (같을 때는 제외)

m/d/y IS n DAY(S) AFTER: 보고서에 적힌 날짜가 숙제 마감일보다 7일후 이내 일 때 (같을 때는 제외)

SAME DAY: 보고서에 적힌 날짜와 숙제 마감일이 같을 때

OUT OF RANGE: 보고서에 적힌 날짜가 숙제 마감일보다 7일 후 또는 7일 전 안에 있지 않을 때

m/d/y는 월/일/연이고, y는 1999년 보다 크거나 같고, 2201년 보다 작거나 같다. 이 때, 숙제 마감일은 매년 같기 때문에, y가 같은 필요는 없다.

예제 입력 1

7
11/20/2005 11/21
11/20/2005 11/17
11/20/2005 11/20
11/20/2005 11/13
11/20/2005 11/28
1/2/2005 12/30
12/31/2100 1/3

예제 출력 1

11/21/2005 IS 1 DAY AFTER
11/17/2005 IS 3 DAYS PRIOR
SAME DAY
11/13/2005 IS 7 DAYS PRIOR
OUT OF RANGE
12/30/2004 IS 3 DAYS PRIOR
1/3/2101 IS 3 DAYS AFTER

힌트

W3sicHJvYmxlbV9pZCI6IjI3MzAiLCJwcm9ibGVtX2xhbmciOiIwIiwidGl0bGUiOiJcdWM2MjRcdWIyOThcdWM3NDAgT1MgXHVjMjE5XHVjODFjIFx1YzgxY1x1Y2Q5Y1x1Yzc3YyIsImRlc2NyaXB0aW9uIjoiPHA+XHVkMGRkXHVkNzZjXHViMjk0IE9TXHVjODcwXHVhZDUwXHVjNzc0XHViMmU0LiBcdWM3NzRcdWJjODggXHVjMjE5XHVjODFjXHViMjk0IFx1YWMwNFx1YjJlOFx1ZDc4OCBwaW50b3NcdWFjMDAgXHViM2Q5XHVjNzkxXHVkNTU4XHViMjk0IFx1ZDY1NFx1YmE3NFx1Yzc0NCBcdWNlYTFcdWNjZDBcdWQ1NWMgXHViMmU0XHVjNzRjXHVjNWQwLCBcdWM3NzRcdWI5N2MgXHVkNTA0XHViOWIwXHVkMmI4XHVkNTc0XHVjMTFjIFx1YzgxY1x1Y2Q5Y1x1ZDU1OFx1YjI5NCBcdWFjODNcdWM3NzRcdWIyZTQuIFx1ZDU1OVx1YzBkZFx1YjRlNFx1Yzc0MCBcdWJjZjRcdWFjZTBcdWMxMWNcdWM1ZDAgXHVjNzk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ZuYnNwOzxcL3A+XHJcbiIsImhpbnQiOiIiLCJvcmlnaW5hbCI6IjEiLCJwcm9ibGVtX2xhbmdfY29kZSI6Ilx1YzYwMVx1YzViNCJ9XQ==

출처

ACM-ICPC > Regionals > North America > Greater New York Region > 2005 Greater New York Programming Contest B번

  • 문제를 번역한 사람: baekjoon
  • 문제의 오타를 찾은 사람: sloth