How Partial Scoring Actually Works
Subtask structure, score arithmetic, and why 40 secure points beat 0 attempted-perfect points.
How Partial Scoring Actually Works
An HSG problem is rarely pass/fail. The statement hides a ladder:
- Subtask 1 (small n): the constraints are so weak that anything correct works.
- Subtask 2 (medium n): a polynomial improvement is required.
- Subtask 3 (full n): the intended complexity, often n log n or better.
The ladder is a gift: it tells you, before you think at all, what complexity the full solution needs. n ⤠20 whispers bitmask or exponential-with-pruning; n ⤠2000 allows O(n²); n ⤠2·10ⵠdemands O(n log n). Constraints are the problem statement's own hints about its solution.
The banking strategy
The contest-optimal opening move is the same in every strong competitor's playbook: read all problems, bank the guaranteed subtask, then climb.
- Solve subtask 1 of every problem with a slow-but-obviously-correct brute force. This is floor insurance: even if your clever ideas all fail, the floor is banked.
- Only then attack the full solution of the problem you understand best.
- Near the end, convert remaining time into either (a) a better complexity on your strongest problem, or (b) one more subtask somewhere.
Why this ordering wins: partial points are concave. The first 40 points of a problem cost 15 minutes; the last 20 often cost an hour of subtle insight. Banking floors everywhere first maximizes total score per minute spent.
Reading the ladder
When you see subtasks, extract three facts immediately:
- The brute-force subtask's bound ā write that brute force first, it is nearly free points and doubles as your stress-test oracle later.
- The full bound ā compute the complexity budget: for n = 2Ā·10āµ you have roughly 10āø simple operations; anything asymptotically worse must go.
- The gap between subtasks ā a jump from n ⤠5000 to n ⤠2Ā·10āµ screams "the O(n²) is the intended trap; find the n log n."
In this module's problems you will do exactly this: pass subtask 1 with the brute force (verified for real), then the full solution (also verified), and watch the shortcut that skips the brute force fail its big test.