The fix is a refusal: the combined ratio exists only when all four components do. This is, almost token for token, what the product's
SubmissionMetricsscope ships — the exercise makes you rediscover why.
The metrics
static double Premium100(Pack p) => p.RateOnLine * p.Limit;
static double? CombinedRatio(Pack p)
=> p is { LossRatio: double lr, Brokerage: double b, CedingCommission: double c, ExpenseRatio: double e }
? lr + b + c + e
: null;
The pattern-match is the whole idea: it only deconstructs when every component is a real double, so Léman's missing loss ratio makes the entire expression null. No sentinel zeros, no ?? 0.0 — the absence propagates.
What the numbers say
- Premium @100% = 195,000 — price math never waits for economics; the pack states the rate.
- Léman CR = null → data-quality referral to the Head of LoB. In Lesson 2 you will see this exact rule in the rulebook:
MissingFinancialstrips whenCombinedRatio is null, and its escalation is the Head of LoB. The desk's next move is not a guess — it is a request to Léman for the loss history. - Control CR = 0.70 + 0.10 + 0 + 0.06 = 0.86 — with data on file, the derivation is trivial. The discipline is entirely about without.
Live and green
Implement Premium100 and a null-honest CombinedRatio (pattern-match all four components, else null) for the Léman PA XL pack; show all three checks green: premium 195,000, Léman CR null with the Head-of-LoB referral line, control CR 86%.
← Back to the exercise · Lesson 1 — The submission · All solutions