FA-60770 / Loyalty points ledgers / Member archive
Points plus cash split: minimum cash reservation · case 05
Awards are fully paid with points although a cash co-pay is required.
Case contract
Input {price, balance, cpp10 (point value in tenths of a cent), min_cash}. Points may cover at most price - min_cash (never negative): max points = floor((price - min_cash)*10/cpp10), limited by balance. Credit = floor(points*cpp10/10); cash = price - credit. Return {points, cash}.
Why this case matters
Member point balances, statements and the program liability depend on this ledger rule.
One recorded failure
Sample boundary fixtureThis sample comes from the broken implementation of a controlled reproducer.
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| points cover most | {"cash": 1, "points": 8333} | {"cash": 506, "points": 7912} | 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 ↗