Boost every heat
First select the highest entry using the supplied comparison callback, keeping the earlier entry on a tie. Then publish one rule at each bonus setting and evaluate those rules later, after the setting has changed. Finally normalize each heat: read fractional marks exactly, remove no-shows coded as 0, apply this meet’s below-6 adjustment and reconcile the count of adjusted marks across all heats.
What needs to change
Repair main so the boosted count covers every heat.
Reproduce
- Build with rustc --edition=2024 main.rs -o main, then pipe the sample heats into ./main and compare the boosted line with the expected stdout.
Acceptance criteria
Your review marks · Saved in this browser. Test acceptance is tracked separately.
Notes
The file contains its imports, read_lines, parse_heat, apply_all and main with its output lines.
Input: up to 50 heats, one per line, each with 1..50 finite marks in steps of 0.5 from -100 to 100, separated by ordinary spaces/tabs. Input 0 denotes a no-show. The supplied reader receives valid data.