| The 2026 CCPC Online Contest |
|---|
| Закончено |
To enhance the suspense and spectator appeal of the contest, the CCPC has introduced a new format featuring a "dynamic scoreboard/balloon-awarding" system. Under this format, the specific problem numbers solved by each team are not displayed immediately during the contest; instead, the scoreboard is revealed dynamically.
Introduction to the new CCPC rules According to the rules, the scoreboard status for a specific problem "unfreezes" when any one of the following three conditions is met:
Although the new format has not yet been officially finalized and is not used in the online contest, please implement this new rule for this problem to better prepare for the upcoming on-site contests.
Given a contest with $$$n$$$ participating teams, a problem solved by $$$m$$$ teams, and the current time, please determine whether the problem currently meets the criteria for unfreezing.
The first line contains an integer $$$T$$$ ($$$1 \le T \le 100$$$), representing the number of test cases.
The next $$$T$$$ lines each contain two integers $$$n,m$$$ ($$$2\leq n\leq 10^4$$$, $$$0\leq m\leq n$$$) and a string in "HH:MM" format, representing the total number of teams, the current number of teams that have solved a specific problem, and the current time, respectively. The input guarantees that the current time is between "00:00" and "05:00" (inclusive).
For each test case, output "YES" if the unfreezing condition is met, or "NO" otherwise.
5100 50 00:00100 10 03:59100 10 04:00100 20 02:0010000 0 05:00
YES NO YES YES YES
| Название |
|---|


