Segmented Rollout Decision Under Profit and CAC Trade-Offs

Medium · Analytics & Experimentation · Data Scientist · Technical Screen

Prompt

You are reviewing 28-day summary results from an A/B experiment on a consumer fintech product, broken out across two user segments. Using the metric rules and cohort tables below, determine whether to roll out Treatment to 100% of users, restrict it to a single segment, or hold back completely, backing every conclusion with explicit math.

Metric rules (fixed overhead is unaffected across variants, and no unmodeled side effects occur):

  • revenue: total gross top-line revenue ($).
  • cost: variable non-marketing servicing and fulfillment expense (COGS, $).
  • CPA: acquisition marketing spend per newly converted customer ($), charged solely on new_customers.
  • profit: revenue - cost - (CPA * new_customers).
  • LTV: projected lifetime gross margin dollars per acquired customer ($).

28-day experiment summary:

Segment Variant revenue cost CPA new_customers LTV
Segment A (new users) Control 150,000 70,000 60 800 210
Segment A (new users) Treatment 130,000 64,000 50 1,200 200
Segment B (existing users) Control 250,000 140,000 70 500 252
Segment B (existing users) Treatment 290,000 160,000 60 600 264

Address all five parts:

  1. Calculate 28-day profit for Control and Treatment in both segments, plus the incremental profit (Treatment - Control) per segment and combined.
  2. Calculate LTV / CAC for every segment-variant pair. Set CAC = CPA for Segment A; for Segment B, treat CPA as incremental campaign cost per newly converted customer and state the assumptions required for that ratio to be valid.
  3. Suppose engineering supports only an all-or-nothing rollout (100% or 0% globally). Derive the algebraic formula and numeric CPA ceiling in Segment A (holding other observed figures fixed) that makes a 100% launch break-even in 28-day profit versus Control.
  4. Suppose Segment B accounts for x% of overall traffic and Segment A accounts for (100 - x)%. Algebraically derive the minimum traffic percentage x at which shipping Treatment to both segments increases combined 28-day profit.
  5. Make a clear launch recommendation (Segment B only, 100% rollout, or 0% hold), highlight two substantive business or scaling risks, and specify one pre-decision follow-up analysis.

Scope & Expectations

  • Segmented accounting vs. unit economics: Accurately compute 28-day net profit alongside LTV / CAC and reconcile why short-window profit and lifetime unit-economics ratios can move in opposite directions.
  • Break-even threshold derivations: Set up clean linear inequalities for both the constant-volume Segment A CPA ceiling and the traffic-mix weight x%, noting practical auction and sample-size caveats.
  • Decision judgment under uncertainty: Weigh realized 28-day margin per customer against modeled LTV, surface concrete risks such as cross-product cannibalization or ad-auction saturation, and design a rigorous cohort/statistical validation check.

Step-by-step walkthrough

  1. Translate the business terms into exact formulas

    Before touching the cohort numbers, write down each metric in plain language and exact arithmetic so every calculation below is a clean plug-in:

    • Gross revenue (revenue): total money brought in from customers before subtracting any expenses.
    • Cost (cost, non-marketing COGS): COGS (Cost of Goods Sold) is the direct variable cost of serving customers — such as payment processing or card-network fees — excluding marketing spend.
    • Gross margin (GM): the money left over from revenue after paying direct serving costs (revenue - cost).
    • CPA (Cost Per Acquisition): the marketing cost spent to acquire one newly converted customer. Total acquisition spend is CPA * new_customers.
    • 28-day profit (profit): gross margin minus acquisition spend over the 28-day window.
    • LTV (Lifetime Value): the total gross margin dollars a single customer is expected to generate across their entire relationship with the company.
    gross_margin       = revenue - cost
    acquisition_spend  = CPA * new_customers
    profit_28d         = gross_margin - acquisition_spend
    incremental_profit = profit_28d(Treatment) - profit_28d(Control)
    LTV_to_CAC         = LTV / CPA
    

    State three baseline assumptions up front so your reasoning is transparent:

    1. Equal traffic per arm within a segment: Control and Treatment received the same traffic split inside Segment A (and inside Segment B), so raw dollar totals can be compared directly.
    2. Fixed costs cancel out: engineering salaries and corporate overhead do not change between arms, so they drop out of every Treatment - Control subtraction.
    3. 28-day accounting vs. lifetime value: profit_28d deducts 100% of a customer's upfront acquisition cost today while counting only their first 28 days of gross margin. Also, summary tables give point estimates without user-level variance, so we cannot compute p-values from these aggregates alone.
  2. Part 1: Compute 28-day profit and incremental profit by segment

    Substitute each row into profit = (revenue - cost) - (CPA * new_customers):

    Segment A (new users)
      Control:    GM = 150,000 - 70,000 =  80,000 | Spend = 60 *   800 = 48,000 | Profit =  32,000
      Treatment:  GM = 130,000 - 64,000 =  66,000 | Spend = 50 * 1,200 = 60,000 | Profit =   6,000
      Incremental (Treatment - Control):  -14,000 GM, +12,000 spend           -> Delta = -26,000 (-81.25%)
    
    Segment B (existing users)
      Control:    GM = 250,000 - 140,000 = 110,000 | Spend = 70 * 500 = 35,000 | Profit =  75,000
      Treatment:  GM = 290,000 - 160,000 = 130,000 | Spend = 60 * 600 = 36,000 | Profit =  94,000
      Incremental (Treatment - Control):   +20,000 GM, +1,000 spend            -> Delta = +19,000 (+25.33%)
    
    Combined (A + B)
      Control total   = 32,000 + 75,000 = 107,000
      Treatment total =  6,000 + 94,000 = 100,000
      Full-launch incremental profit    = -26,000 + 19,000 = -7,000 (-6.54%)
    

    Segment A and Segment B move in opposite directions: in Segment A, Treatment loses $14,000 in gross margin while spending $12,000 more on acquisition (-$26,000 net); in Segment B, it adds $20,000 in gross margin for just $1,000 in extra spend (+$19,000 net). We can double-check all arithmetic in Python:

    segments = {
        "A": {
            "control": (150_000, 70_000, 60, 800),
            "treatment": (130_000, 64_000, 50, 1_200),
        },
        "B": {
            "control": (250_000, 140_000, 70, 500),
            "treatment": (290_000, 160_000, 60, 600),
        },
    }
    
    
    def compute_profit(revenue: int, cost: int, cpa: int, new_customers: int) -> int:
        gross_margin = revenue - cost
        acquisition_spend = cpa * new_customers
        return gross_margin - acquisition_spend
    
    
    for seg_name, arms in segments.items():
        control_profit = compute_profit(*arms["control"])
        treatment_profit = compute_profit(*arms["treatment"])
        delta = treatment_profit - control_profit
        print(f"Segment {seg_name}: Control={control_profit}, Treatment={treatment_profit}, Delta={delta:+d}")
    # Segment A: Control=32000, Treatment=6000, Delta=-26000
    # Segment B: Control=75000, Treatment=94000, Delta=+19000
    
  3. Part 2: Compute LTV/CAC and clarify existing-user assumptions

    Unit economics measures whether a single acquired customer generates more lifetime gross margin than it costs to acquire them. Using CAC (Customer Acquisition Cost, the marketing cost to win one customer) equal to CPA, divide LTV by CPA for every cell:

    Segment     Control LTV/CAC            Treatment LTV/CAC          Change
    Segment A   210 / 60 = 3.50            200 / 50 = 4.00            +0.50 (+14.3%)
    Segment B   252 / 70 = 3.60            264 / 60 = 4.40            +0.80 (+22.2%)
    

    Both segments show healthier LTV / CAC under Treatment: in Segment A, a 16.7% drop in CPA ($60 -> $50) more than offsets a 4.8% dip in LTV ($210 -> $200); in Segment B, LTV rises while CPA falls.

    Why do "existing users" in Segment B have a CPA and new_customers count at all? In a multi-product fintech app (for example, cross-selling a credit-builder card or high-yield savings feature to existing checking members), new_customers counts existing members who newly adopt the promoted product. Treating CAC = CPA for Segment B requires three explicit assumptions:

    1. Incremental conversions: the 500 (Control) and 600 (Treatment) conversions happened because of the cross-sell campaign, rather than organically for $0. (If many would have converted anyway without marketing, true CAC per incremental conversion is higher than $70 or $60.)
    2. Incremental marketing cost only: CPA includes only the new cross-sell campaign or incentive spend per converted user; their original sign-up acquisition cost is a sunk cost from the past.
    3. Incremental LTV: the $252 and $264 LTV figures must represent the additional lifetime gross margin created by adopting the new product. If $252 is the user's entire account LTV (much of which they would generate even without converting), LTV / CAC in Segment B is overstated.

    It also helps to check marginal CAC — the extra marketing dollars divided by the extra customers gained when moving from Control to Treatment:

    Segment A marginal CAC = (60,000 - 48,000) / (1,200 - 800) = 12,000 / 400 = $30.00 per extra customer
    Segment B marginal CAC = (36,000 - 35,000) / (  600 - 500) =  1,000 / 100 = $10.00 per extra customer
    
  4. Part 3: Solve for the Segment A CPA cap under an all-or-nothing launch

    If we must ship to 100% of users or 0% of users, Segment B's +$19,000 profit gain can subsidize at most a -$19,000 profit loss in Segment A. Let c be Segment A's Treatment CPA while holding Segment A's gross margin ($66,000) and new customers (1,200) fixed:

    Profit_A_treatment(c) = (130,000 - 64,000) - 1,200 * c
                          = 66,000 - 1,200 * c
    
    Delta_A(c)            = Profit_A_treatment(c) - Profit_A_control
                          = (66,000 - 1,200 * c) - 32,000
                          = 34,000 - 1,200 * c
    
    Global break-even:    Delta_A(c) + Delta_B >= 0
                          (34,000 - 1,200 * c) + 19,000 >= 0
                          53,000 - 1,200 * c >= 0
                          1,200 * c <= 53,000
                          c <= 53,000 / 1,200 = 265 / 6 = $44.17 (nearest cent; exact 44.1666...)
    

    So Segment A's Treatment CPA must be capped at $44.17 (or $44.16 if rounded strictly downward in whole cents — down $5.83, or 11.7%, from $50.00) for a 100% launch to be profit-neutral against Control.

    Quick sanity check: a full launch currently falls short by $7,000 across 1,200 new customers in Segment A, which is $7,000 / 1,200 = $5.8333... per customer ($50.00 - $5.8333... = $44.1666...). Note two practical caveats:

    • If Segment A had to break even on its own without Segment B's subsidy, the cap would be 34,000 / 1,200 = 85 / 3 = $28.33.
    • In real ad auctions, lowering your bid cap to reduce CPA usually reduces conversion volume below 1,200, which also changes Segment A's revenue and COGS. Thus $44.17 is a constant-volume threshold.
  5. Part 4: Derive the minimum traffic share x% for Segment B

    Suppose Segment B makes up x% of total traffic and Segment A makes up (100 - x)%. Assuming the two tables represent equal-sized traffic samples (for example, profit per 10,000 visitors in each segment), Segment B contributes +$19,000 per traffic block and Segment A contributes -$26,000 per traffic block. (If the raw tables came from unequal sample sizes N_A and N_B, you would divide each segment's profit delta by its sample size first.)

    Write the traffic-weighted incremental profit and solve for Expected_Lift(x) > 0:

    Expected_Lift(x) = (x / 100) * 19,000 + ((100 - x) / 100) * (-26,000) > 0
    
    Multiply both sides by 100:
      19,000 * x - 26,000 * (100 - x) > 0
      19,000 * x - 2,600,000 + 26,000 * x > 0
      45,000 * x > 2,600,000
      x > 2,600,000 / 45,000 = 520 / 9 = 57.7777...%
    

    Segment B must represent more than 57.78% of total traffic (520 / 9 %) for a full launch to improve overall 28-day profit. Check three traffic mixes to verify:

    Traffic share of B (x)   Weighted lift per block: (x/100)*19,000 + ((100-x)/100)*(-26,000)
    x = 50.00%               0.5000 * 19,000 - 0.5000 * 26,000 =  -$3,500.00  (loses money, matches Part 1 sign)
    x = 57.78%               0.5778 * 19,000 - 0.4222 * 26,000 =   +$1.00     (just above break-even)
    x = 70.00%               0.7000 * 19,000 - 0.3000 * 26,000 =  +$5,500.00  (solidly profitable)
    
  6. Reconcile 28-day profit loss with higher LTV/CAC in Segment A

    Before making a launch call, confront the tension between Part 1 and Part 2: why does Segment A lose -$26,000 in 28-day profit while its LTV / CAC climbs from 3.50 to 4.00?

    If we evaluate each 28-day cohort on projected net lifetime value (new_customers * (LTV - CPA)), assuming LTV already includes the first 28 days of margin:

    Segment     Control net cohort LTV             Treatment net cohort LTV           Cohort lift
    Segment A   800 * (210 - 60) = $120,000        1,200 * (200 - 50) = $180,000      +$60,000
    Segment B   500 * (252 - 70) =  $91,000          600 * (264 - 60) = $122,400      +$31,400
    

    Notice that both Control and Treatment in Segment A earn $150 of projected net LTV per customer (210 - 60 = 150 and 200 - 50 = 150), and Treatment acquires 400 more customers (400 * $150 = +$60,000).

    Why not launch to Segment A immediately on that +$60,000 figure? Because in a 28-day experiment, LTV for newly acquired Treatment users is a model prediction, not observed cash. Look at realized 28-day gross margin per new customer in Segment A:

    • Control: $80,000 / 800 = $100.00 gross margin per new customer in the first 28 days.
    • Treatment: $66,000 / 1,200 = $55.00 gross margin per new customer in the first 28 days (a 45.0% drop!).

    Early realized margin per customer fell almost in half, yet the LTV model barely moved ($210 -> $200, -4.8%). Unless customers delay spending in month 1 and genuinely catch up later, the LTV model is likely over-predicting low-intent customers brought in by cheaper acquisition channels.

  7. Part 5: Final launch recommendation, key risks, and follow-up analysis

    Decision option              28-day total profit   Lift vs. Control
    Hold (0% launch)             $107,000                $0      (0.0%)
    Launch to all (A + B)        $100,000              -$7,000   (-6.5%)
    Launch to Segment B only     $126,000              +$19,000  (+17.8%)
    

    Recommendation: Launch to Segment B only, and hold Segment A in the experiment.

    Segment B wins on every lens: +$19,000 (+25.3%) in 28-day segment profit, higher LTV / CAC (3.60 -> 4.40), and +$31,400 in projected cohort LTV. A global launch fails both thresholds (CPA = $50 > $44.17 cap, and equal-weight profit is -$7,000).

    Two key risks and trade-offs:

    1. Diminishing returns at scale and cannibalization in Segment B. Cannibalization happens when a promoted feature merely shifts a customer's spending away from another product they already use (or pulls next month's transactions into this month) instead of creating net-new margin. In addition, $60 CPA was achieved at test budget; scaling to 100% of Segment B often exhausts the cheapest campaign inventory and pushes CPA upward.
    2. Foregoing potential long-term growth in Segment A. Holding Segment A back protects $26,000 in 28-day profit per period, but if the $200 LTV forecast turns out to be accurate (meaning month-1 margin was merely delayed, not lost), holding Segment A gives up 400 profitable new customers (+$60,000 in lifetime value) every 28 days.

    One follow-up analysis before a final go/no-go:

    Run a 60-to-90-day cohort payback curve with user-level bootstrap confidence intervals. First check for sample ratio mismatch (SRM) — verifying that user counts split evenly between Control and Treatment as designed — and resample individual users with replacement (bootstrapping) to confirm Segment B's +$19,000 gain has a 95% confidence interval strictly above $0. Simultaneously, plot cumulative realized gross margin per acquired customer at days 30, 60, and 90 in Segment A to test whether Treatment cohorts actually bend upward toward $200 LTV or plateau far below it.

Intuition & how it works

Think of evaluating this A/B test like running two neighborhood storefronts — Storefront A for brand-new shoppers and Storefront B for loyal regulars — while testing a new promotional display. To know whether the promotion actually makes money this month, you cannot just check cash-register sales (revenue) or even sales minus wholesale item cost (gross margin); you also have to subtract what you paid flyers and ads to bring newly converted shoppers through the door (CPA * new_customers).

Looking at only one headline number leads straight into a trap. If you look only at total revenue ($400k Control vs. $420k Treatment) or only at lifetime efficiency ratios (LTV / CAC rises in both segments!), you would ship the feature everywhere and immediately lose $7,000 in 28-day profit. Conversely, if you look only at the pooled -$7,000 total and kill the feature completely, you throw away a clean +$19,000 profit win among existing users.

Walking through the numbers segment by segment makes the right call clear:

  • Segment A (new users): Gross margin (revenue - cost) drops from $80,000 to $66,000 (-$14,000), while marketing spend (CPA * new_customers) rises from 60 * 800 = $48,000 to 50 * 1,200 = $60,000 (+$12,000). Net 28-day profit falls from $32,000 to $6,000 (-$26,000).
  • Segment B (existing users): Gross margin rises from $110,000 to $130,000 (+$20,000), while marketing spend barely moves from 70 * 500 = $35,000 to 60 * 600 = $36,000 (+$1,000). Net 28-day profit climbs from $75,000 to $94,000 (+$19,000).
  • Targeted decision: Shipping only to Segment B keeps Segment A at $32,000 and lifts Segment B to $94,000, raising total profit from $107,000 to $126,000 (+$19,000, or +17.8%).

Key points

  • 28-day profit by segment: Using profit = revenue - cost - (CPA * new_customers) where COGS (cost, Cost of Goods Sold) is direct non-marketing serving cost and CPA (Cost Per Acquisition) is marketing spend per new customer, Segment A drops by -$26,000 ($32,000 -> $6,000), Segment B gains +$19,000 ($75,000 -> $94,000), and a full launch loses -$7,000 ($107,000 -> $100,000).
  • Unit economics (LTV / CAC) improves in both segments: Dividing LTV (Lifetime Value, total lifetime gross margin per customer) by CAC (Customer Acquisition Cost, set equal to CPA) gives 3.50 -> 4.00 in Segment A and 3.60 -> 4.40 in Segment B. Short-term profit can fall while LTV / CAC rises because 28-day profit charges 100% of upfront acquisition spend against only one month of realized gross margin.
  • Existing-user CAC assumption: In Segment B, treat new_customers as existing app users who newly adopt a cross-sold product because of the campaign, CPA as incremental cross-sell marketing spend per conversion, and LTV as the extra lifetime gross margin created by that conversion. Marginal CAC (extra spend divided by extra conversions vs. Control) is $30 in A ($12,000 / 400) and $10 in B ($1,000 / 100).
  • Global CPA cap for Segment A: For an all-or-nothing launch to break even (Delta_A + 19,000 >= 0), Segment A's Treatment CPA must satisfy (66,000 - 1,200 * c - 32,000) + 19,000 >= 0, giving c <= 53,000 / 1,200 = 265 / 6 = $44.17 (assuming constant volume of 1,200 customers; standalone break-even for A alone is 34,000 / 1,200 = $28.33).
  • Minimum Segment B traffic share: Assuming equal-traffic segment tables, (x / 100) * 19,000 + ((100 - x) / 100) * (-26,000) > 0 simplifies to 45,000 * x > 2,600,000, so Segment B must exceed 57.78% (520 / 9 %) of total traffic for a global launch to increase profit.
  • Launch recommendation: Ship to Segment B only (+$19,000), watch for ad-scale inflation and cannibalization (revenue shifted away from other products the user already uses), keep Segment A in test, and run a 60–90-day cohort payback analysis with user-level confidence intervals.

Common mistakes

  • Ignoring marketing spend when computing profit: Comparing only revenue (-$20,000 in A, +$40,000 in B) or only gross margin (-$14,000 in A, +$20,000 in B) forgets CPA * new_customers and falsely makes a full launch look profitable (+$20,000 revenue or +$6,000 margin instead of -$7,000 profit).
  • Shipping to all users based solely on LTV / CAC: Declaring victory everywhere because 4.00 > 3.50 in Segment A ignores both the -$26,000 28-day profit drop and the red flag that realized 28-day margin per new customer fell 45.0% ($100.00 -> $55.00) while modeled LTV barely moved ($210 -> $200).
  • Rounding Part 4 downward to 57.77% without checking the sign: Because the exact threshold is 520 / 9 = 57.7777...%, plugging in x = 57.77% actually yields a small loss (-$3.50 per block); the minimum profit-improving share is strictly above 57.78% (when rounded to two decimal places).
  • Treating the $44.17 CPA cap as guaranteed to preserve 1,200 conversions: In paid acquisition auctions, lowering bids to force CPA down from $50.00 to $44.17 almost always reduces new_customers below 1,200, changing gross margin as well. Always note the constant-volume assumption.
  • Claiming statistical significance from aggregate totals: Without user-level standard deviations or sample sizes, +$19,000 is a point estimate; you must request user-level data to compute confidence intervals before calling the lift statistically significant.

Follow-up questions

  • How would you test whether Segment B's +$19,000 profit improvement is statistically significant rather than random sampling noise? Pull user-level experiment logs for Segment B and compute net 28-day profit per randomized user (including users with $0 revenue so the denominator stays unbiased). First run a sample ratio mismatch (SRM) chi-square test on user counts to confirm the Control/Treatment traffic split wasn't corrupted, then use bootstrapping — repeatedly resampling users with replacement within each arm — to construct a 95% confidence interval for incremental profit; if the entire interval sits above $0, the gain is statistically solid.
  • If you roll the experience out only to Segment B, how should engineering handle Segment A users as they age into existing users? Gate the feature behind a server-side feature flag keyed on clear eligibility criteria (for example, account tenure >= 30 days) so users graduate cleanly into the Segment B experience once their onboarding window finishes rather than flickering mid-session. Keep a small long-term holdout (such as 5% of Segment B users held on Control for 90 days) to verify that the lift persists and is not just pulled-forward spending.
  • What specific outcomes from your follow-up cohort study would justify expanding the rollout to Segment A later? Either of two measurable outcomes would flip Segment A to a "go": (1) the 60–90-day cohort payback curve shows Treatment customers catching up in cumulative gross margin along the $200 LTV trajectory, proving the -$26,000 month-1 dip was purely upfront timing and confirming the +$60,000 cohort LTV gain; or (2) bid/creative optimization brings Segment A's Treatment CPA down to $28.33 or below at roughly 1,200 conversions, making Segment A profitable even within the first 28 days.

Follow-up questions

Similar questions

More Chime interview questions

All 18 Chime questions →