| 시간 제한 | 메모리 제한 | 제출 | 정답 | 맞힌 사람 | 정답 비율 |
|---|---|---|---|---|---|
| 3 초 (추가 시간 없음) | 1024 MB | 71 | 33 | 26 | 50.980% |
As a coach of 2ドルn$ students, you are making $n$ duos (teams of two) for the upcoming programming contest season. After the duos have been created, they will participate in $r$ contests, each about a different topic: DP, graphs, geometry, etc. You already ran a set of internal selection contests to rank the students, and from this you were able to rank all the students with a unique integer score between 1ドル$ and 2ドルn$ inclusive for each topic, with 2ドルn$ being the best.
When a duo participates in a contest on a given topic, their score will be the maximum of the two scores of the two students for this topic.
You think it would be amazing if summed up over all duos and contests, your students could achieve a total score of at least $\frac 12 rn(3n+1)$. Is this possible?
The input consists of:
If it is possible to make duos such that the total score over all duos and contests is at least $\frac 12 rn(3n+1),ドル output "possible". Otherwise, output "impossible".
2 2 1 2 3 4 1 2 3 4
possible
2 2 1 2 3 4 4 1 2 3
possible
2 3 1 2 3 4 4 1 2 3 1 3 2 4
impossible
ICPC > Regionals > Europe > Northwestern European Regional Contest > Benelux Algorithm Programming Contest > BAPC 2023 Preliminaries D번