FA-68647 / Toll and parking fee computation / Member archive
One-way bridge toll with frequent-user discount: carpools of exactly the minimum occupancy are charged · case 02
One-way bridge toll with frequent-user discount returns a wrong result when carpools of exactly the minimum occupancy are charged.
Case contract
Input {trips: [[month index, direction, occupancy]], toll_dir, base, threshold, discount_pct, carpool_min}. Only trips in toll_dir are tolled. Carpools (occupancy >= carpool_min) are free and do not count. Paid trips are counted per month index (no carry-over between months); trips beyond threshold in a month pay floor(base*(100-discount)/100).
Why this case matters
Fee engines bill customers in integer cents; a wrong boundary, rounding stage or cap scope silently over- or under-charges.
One recorded failure
Sample boundary fixtureThis sample comes from the broken implementation of a controlled reproducer.
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| fee oracle 0 | 3145 | 2660 | Failed |
MEMBER ARCHIVE
The complete case is available to members.
This record includes three runnable implementations, regression fixtures, execution results, and source hashes.
Member access is invitation-based. Sign in with your invited account to inspect the sources.
Sign in to the archive ↗