FA-85630 / Ride-hailing fare and surge pricing / Member archive
Flat fare only applies in the stored direction · case 05
Downtown-to-airport trips are metered while airport-to-downtown is flat.
Case contract
Zone names are case-insensitive (normalized upper case). A flat fare table keyed "A|B" applies in both directions; a flat fare (0 is a valid promotional flat) is never surged. Otherwise the metered fare is surged (tenths, half up). Airport fees apply separately: the pickup fee of the pickup zone and the dropoff fee of the dropoff zone. Tolls are added last. Return [fare, flat|metered].
Why this case matters
Ride-hailing prices are computed per trip at scale; ordering, unit and boundary slips become systematic over- or under-charging.
One recorded failure
Sample boundary fixtureThis sample comes from the broken implementation of a controlled reproducer.
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| regression: reverse direction lookup | [3692, "metered"] | [4800, "flat"] | 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 ↗