Logo
(追記) (追記ここまで)

31592번 - Online Assignment 다국어인터랙티브

시간 제한메모리 제한제출정답맞힌 사람정답 비율
2 초 1024 MB111594252.500%

문제

You have to finish an assignment by the end of today. You can submit the assignment online and, even if your submission is rejected, you still have several more submission chances.

The assignment consists of five questions, each of which asks whether or not a given statement is true. For each submission, you have to submit answers for all five questions. If your answers are correct for all the questions, your assignment is completed. However, if any of your answers are wrong, your submission is rejected, and the number of correct answers will be told.

All the questions are so difficult that you cannot give confident answers to any of them. Your task here is to write a program that tries to submit answers repeatedly until the assignment is completed. Note that you can submit answers only a limited number of times.

인터랙션

For each submission, your program should output exactly five characters without any delimiters followed by a newline to the standard output. Each character should be either t or f. The $i$-th character being t means the statement of the $i$-th question is judged to be true. Similarly, the character f means it is judged to be false.

After the output, you will receive a feedback from the standard input: either “rejected $C$” or “completed” followed by a newline. When you receive rejected $C,ドル it means that at least one of your answers is wrong, and $C$ is the number of correct answers. In this case, your program should submit another answer. When you receive completed, your assignment is completed. Your program should terminate without extra output.

Your program can submit answers at most 12ドル$ times. If your 12ドル$-th submission is still rejected, your program will be judged as “Wrong Answer”.

Notes on interactive judging:

  • The evaluation is non-adversarial, meaning that the correct answers to the questions are chosen in advance rather than in response to your submissions.
  • Do not forget to flush output buffers after writing. See the “Judging Details” document for details.
  • You are provided with a command-line tool for local testing, together with input files corresponding to the sample interactions. You can download these files from DOMjudge. The tool has comments at the top to explain its use.

입력

출력

제한

예제 입력 1

tffft
fffft
ttfft

예제 출력 1

rejected 4
rejected 3
completed

예제 입력 2

fffff

예제 출력 2

completed

힌트

출처

ICPC > Regionals > Asia Pacific > Asia Pacific Championship > The 2024 ICPC Asia Pacific Championship 연습 세션 PC번

ICPC > Regionals > Asia Pacific > Asia Pacific Championship > The 2025 ICPC Asia Pacific Championship 연습 세션 C번

채점 및 기타 정보

  • 예제는 채점하지 않는다.
(追記) (追記ここまで)

출처

대학교 대회

  • 사업자 등록 번호: 541-88-00682
  • 대표자명: 최백준
  • 주소: 서울시 서초구 서초대로74길 29 서초파라곤 412호
  • 전화번호: 02-521-0487 (이메일로 연락 주세요)
  • 이메일: contacts@startlink.io
  • 통신판매신고번호: 제 2017-서울서초-2193 호

AltStyle によって変換されたページ (->オリジナル) /