Keep a tie policy explicit

The manual lecture activity moves boundaries to avoid giving equal marks different grades. The later pseudocode intentionally omits this adjustment. These are different procedures, so they can give different group sizes and hypothesis results.
The lab offers an explicit extension: consider cumulative positions only at the ends of equal-mark runs, including 0 and n. For each target n/4, n/2 and 3n/4, choose the nearest such count; when two boundaries are equally near, choose the lower count. This is a specified teaching policy, not an official grading rule or an exact reconstruction of every spoken classroom adjustment.
| Policy | Maths A/B/C/D counts | Physics A/B/C/D counts |
|---|---|---|
| Exact source positional code | 7 / 7 / 8 / 8 | 7 / 7 / 8 / 8 |
| Nearest whole-run extension | 8 / 7 / 7 / 8 | 8 / 8 / 8 / 6 |
The original supplied cards determine these calculations. Spoken lists and rough counts in the classroom conversation may differ. For example, Naveen’s original card #29 has Physics 66; we retain that value rather than moving him into a higher group to reproduce an approximate spoken count.
Try it yourself
Can all ties be preserved while always forcing exactly equal grade counts?
Show explained answer
Not in general. A large tied group can cross any desired quarter boundary.
Try it yourself
Does the extension change student marks?
Show explained answer
No. It changes only the boundary policy used to group their existing marks.
Try it yourself
Why compare hypothesis fractions under both policies?
Show explained answer
It reveals how a preprocessing choice affects the result instead of treating one grouping as inevitable.
