FA-62098 / Currency rounding and FX conversion / Member archive
Fully offset currencies remain in the settlement instruction list · case 03
A currency that nets to zero still produces a zero payment instruction.
Case contract
solve(trades): each trade is [pay_ccy, pay_amount, recv_ccy, recv_amount] from our side. Net per currency = received - paid. Return [[ccy, net], ...] sorted by currency code, omitting currencies whose net is exactly zero; nets are plain strings at the currency exponent (JPY 0, KWD 3, else 2).
Why this case matters
Currency amounts must be rounded at the right stage and in the right unit, or ledgers, quotes and settlements drift by minor units.
One recorded failure
Sample boundary fixtureThis sample comes from the broken implementation of a controlled reproducer.
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| regression zero-net-omission 1 | [["JPY", "0"], ["USD", "0.00"]] | [] | 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 ↗