Skip to content
Tech Interview Prep

Top 100 Data Scientist Practice MCQs

Every question on one page: open one, choose an answer, and see why at once. Signed in, your latest answer to each question counts, and you can answer again after 24 hours.

Curated: · Written: · Reviewed:

Reviewed 100Review pending 0

Answers to reviewed questions count toward this role and the overall leaderboard; your latest answer to each one is the one that counts.

100 questions

MCQ-51As a sanity check on a new simulator, an engineer runs 10,000 fair coin flips, counts 5,012 heads, and writes "P(heads) = 0.5012" in the report. Which conclusion about that number is correct?
MCQ-52A tracing service stamps every span with a random 32-bit identifier. Over the 30-day retention window the pipeline will emit 100,000 spans. A reviewer signs off because 100,000 is 0.0023% of the 4.29 billion identifiers available. What is the probability that at least two spans in the window share an identifier?
MCQ-42A team's prior belief about a checkout page's conversion rate is Beta(10, 90): a mean of 10% from 100 pseudo-observations. A test brings 40 conversions from 200 visitors. Which posterior should they report as the updated belief?
MCQ-43A composite latency metric S = X + Y sums queue wait X and service time Y. A load test gives Var(X) = 4 ms², Var(Y) = 9 ms², and a correlation of 0.6 between X and Y, because both rise together as the queue builds. An engineer propagates the p99 of S as if X and Y were independent, reporting Var(S) = 13 ms². What variance should be published for S?
MCQ-44A payments API's request latency is right-skewed: across raw requests the mean is 180 ms, the standard deviation is 300 ms, and the empirical 99th percentile is 1,120 ms. The team also samples 40 batches of 200 requests each; the batch means have a standard deviation of 12 ms and their histogram is symmetric and bell-shaped. The team must publish (i) a 95% interval for the true mean latency and (ii) a threshold T that 99% of individual requests finish under. Which plan is right?
MCQ-45A growth team models daily signups as Binomial(n = 4,000, p = 0.15): mean 600, variance 510, so the 95% control limits sit at 600 ± 44. Over a 30-day month the observed daily variance is 2,600 and 11 days breach those limits. Which conclusion should the review accept?
MCQ-46An on-call team models daily incident tickets with a Poisson distribution. Over the last 90 days the mean is 40 tickets/day and the sample variance is 300. They plan to page when a day exceeds the 99th percentile of the fitted Poisson, which is 55. The observed 99th percentile in the same window is 89. They need a model-based threshold for next quarter, not just a fixed historical quantile. What should they do?
MCQ-47A team reports two 95% intervals from the same right-skewed delivery-time sample (n = 400): a confidence interval for the mean and a prediction interval for the next single delivery. On held-out data the mean interval covers 94.6% of targets and the prediction interval covers 71.2%. Which conclusion about the role of the normality assumption in the two intervals is sound?
MCQ-48A retry policy for a job queue assumes exponential (memoryless) wait times and retries at a fixed short interval. Hazard rates measured within one queue, per minute by time since the last failure: 0.180 at 0-5 min, 0.091 at 5-10 min, 0.038 at 10-20 min. Which change addresses the cause?
MCQ-41A payments team screens 1,000,000 card transactions a day. Fraud runs at 0.1% of transactions. Their new model catches 99% of fraudulent transactions and flags 1% of legitimate ones. Before switching on auto-blocking for every flagged transaction, the team wants to know what share of the blocks will be genuine fraud.
MCQ-36A checkout experiment measures a relative lift of +1.0% with a standard error of 1.0%; the two-sided frequentist p is 0.32. The team fits the same likelihood twice, once with a historical prior centred at 0 with sd 2% and once with an optimistic prior centred at +2.5% with sd 1%. The ship bar is P(effect > 0) ≥ 0.95. Leadership asks for one number. What should the readout say?
MCQ-37A colleague's non-inferiority readout for a new anticoagulant reports a difference in event rate (new minus standard) of -0.3%, 95% CI -1.2% to +0.6%, and p = 0.44 against zero. The pre-specified non-inferiority margin is -2%. Which statement should your review accept?
MCQ-30An A/B test on a signup page assigns 25 users to control and 25 to treatment. Control converts 2 users; treatment converts 7. The analyst ran Welch's t-test on the 0/1 conversion indicators and reports a 95% CI for the difference in proportions of (-0.02, 0.42) with p=0.08. Which analysis should replace it?
MCQ-32Thirty users each complete a checkout task on the old UI and on the new UI, in randomised order. Old: mean 42.1 s (SD 18.0). New: mean 38.4 s (SD 17.6). The analyst runs an unpaired t-test, gets t = 0.81, p = 0.42, and reports no effect. The 30 per-user differences average 3.7 s with SD 5.2 s. What should the report conclude?
MCQ-33A payments team reports the 95% interval for the p90 of checkout latency. The measurement design sampled 500 users and recorded every checkout each of them made: 2,500 events in total, and user 47 alone accounts for 400 of them. The team bootstraps the 2,500 events with 1,000 resamples, recomputing the p90 inside each resample, and reports [182 ms, 205 ms]. Which interval should they publish?
MCQ-91A team reports a 95% bootstrap confidence interval for a lift metric to two decimals. Running the same bootstrap on the same data with five different seeds gives lower bounds 1.81–2.06 and upper bounds 3.44–3.71 at 1,000 resamples, and lower bounds 1.92–1.93 and upper bounds 3.57–3.58 at 100,000 resamples. Two analysts who ran it at 1,000 resamples spent a day hunting a data bug because their endpoints differed in the second decimal. What should the team do?
MCQ-39A checkout experiment randomises users. The primary metric is revenue per session: total revenue divided by total sessions, both random at the user level. In the treatment arm, n = 10,000 users, mean revenue per user is $42 with SD $30, mean sessions per user is 60 with SD 40, and the per-user correlation between revenue and sessions is 0.0. The analyst reports the 95% interval for revenue per session as 0.70 ± 0.0098. Which interval is correct?
MCQ-28A pricing test ran 10,000 users per arm. Revenue per user averaged $42.00 in control and $43.80 in treatment: a +$1.80 lift, p = 0.034. Revenue per user has a standard deviation of about $60 in both arms. The team wants to book the +$1.80 as next quarter's planning assumption. Which action is justified?
MCQ-2A checkout A/B test runs 14 days with 50,000 users/day split evenly between control and treatment. Baseline conversion is 4.0%. The result comes back flat: 4.01% treatment vs 4.00% control, and the PM wants to report that the feature has no effect. Which conclusion does the design actually support?
MCQ-26A checkout A/B test ran for two weeks: control 4.2% conversion, treatment 5.0%, a +0.8 percentage-point lift. The 95% confidence interval for the lift is [-0.2 pp, +1.8 pp]. The team's launch rule requires the lower bound of that interval to exceed +0.1 pp. What should the team do?
MCQ-21A two-week A/B test of a checkout change moved revenue per session +0.2% (95% CI −1.1% to +1.5%). The team's ship threshold is +1.0% lift. The readout concludes "no effect: revert." Which review comment should be accepted?
MCQ-27A payments team is testing a checkout change that adds a confirmation step. Baseline conversion is 4.0%. The change will either lift conversion by 0.2 percentage points or cut it by 0.2 percentage points. Shipping a change that actually cuts conversion costs an estimated $400,000 per year in lost revenue; not shipping a change that would have lifted conversion costs $20,000 per year. The team can run 300,000 users per arm. They must fix alpha and power before the test. Which plan should they adopt?
MCQ-99An A/B test randomised 100,000 eligible users 50/50. Before any outcome metric is computed, the randomization check reports 50,740 users in treatment and 49,260 in control; the chi-square goodness-of-fit test on those counts gives χ² = 21.9 on 1 d.f. (p ≈ 3 × 10⁻⁶). What is the correct response?
MCQ-8A growth team reads out 20 metrics from a single experiment at α = 0.05 with no multiplicity control. Five metrics come back below 0.05: checkout completion p = 0.001, add-to-cart rate p = 0.004, session length p = 0.007, support contacts p = 0.02, and coupon views p = 0.04. The analyst applies Benjamini-Hochberg at FDR 0.05 across all 20 metrics. Which metrics survive?
MCQ-25A checkout redesign ran on 250,000 users per arm. Conversion was 4.00% in control and 4.10% in treatment: a +0.10 percentage-point lift, 95% interval +0.01 to +0.19 pp, p = 0.04. The analyst also ran 40 secondary metrics; average order value came back at p = 0.03. Which reading of these numbers is correct?
MCQ-40A growth team's experiment dashboard recomputes a nominal 95% interval every hour and flags any launch whose interval excludes zero; the on-call rotation acts on a flag whenever it appears. Last quarter it flagged eleven launches, four of which reversed in the holdout. The dashboard has to keep refreshing hourly. Which change addresses the cause of the reversals?
MCQ-3A checkout experiment is pre-registered to run 14 days and be read once at the end. The dashboard recomputes the p-value every night, and the team has agreed to ship the moment it drops below 0.05. Which analysis plan would survive peer review?
MCQ-11A proposed plan for cutting variance with a pre-experiment covariate is under peer review: a 14-day experiment on 60,000 users, each user's spend for the 30 days before assignment on file, and a launch decision that rests on the population mean revenue lift. Which analysis plan should the reviewers approve?
MCQ-4A signup-flow experiment was meant to split traffic 50/50. Assignment is server-side, but exposure is logged client-side when the signup page renders. After a week: control 102,400 sessions at 4.1% conversion, treatment 98,600 sessions at 4.6%. The team wants to ship the +0.5pp lift. What should they do?
MCQ-7A subscription app tests a redesigned onboarding flow on a 50/50 split of 2 million new signups over eight weeks. Pooled across the whole test, week-4 retention is +1.5% in the treated group (95% CI +0.4% to +2.6%). Broken out by time since first exposure, the lift is +9.1% on days 0–2, +4.6% on days 3–7, +2.0% on days 8–21, and +0.4% (95% CI −0.5% to +1.3%) on days 22–56. The team plans a permanent global rollout. Which estimate should drive the launch decision?
MCQ-13A team randomized 200,000 users 50/50 to a new feature or the old flow. In the treatment arm, 60% of users used the feature; the other 40% never opened it. 30-day retention came out at 20% in control, 23% across the whole treatment arm, 29% among treatment users who used the feature, and 14% among treatment users who never opened it. The analyst's slide reports a 9-point lift, comparing users who used the feature with control. Which number should the readout report as the effect of the feature?
MCQ-19A checkout redesign was tested in an A/B experiment. A redirect bug routed mobile users to treatment, so treatment ended up 80% mobile and control 80% desktop. Desktop: control 8,000 users converting at 30%, treatment 2,000 at 32%. Mobile: control 2,000 at 5%, treatment 8,000 at 6%. The pooled readout shows treatment at 11.2% against control at 25.0%. Product analytics show the launch population is 50% desktop and 50% mobile. Which effect estimate should the launch decision use?
MCQ-10A three-week A/B test of a new checkout flow (240,000 users) shows a pooled conversion lift of +1.2% at p = 0.03. A PM then slices the data by tenure (4 buckets) × device (3) × region (2) × plan tier (4) = 96 segments and finds "new users, mobile, region B, basic plan" at +9.1%, p = 0.011. She wants to ship the new flow only to that segment. What is the right read?
MCQ-12A four-week pricing test ran with 200,000 users per arm. Raw mean revenue per user is +8.4% in treatment (95% CI +0.2% to +16.6%). One treatment user signed a $1.2M annual contract during the test; dropping that single row leaves +0.4% (95% CI −1.1% to +1.9%). Winsorising at the 99.9th percentile gives +3.1% (−0.6% to +6.8%). The contract had been negotiated before the test began. What should the readout say?
MCQ-31A revenue A/B test ran 40,000 users per arm. Raw revenue per user: control $3.10, treatment $3.62, difference +$0.52, t 95% CI [+$0.04, +$1.00], 10,000-resample bootstrap 95% CI [-$0.18, +$1.22]. Twenty users per arm (0.05%) hold 48% of total revenue. Capping revenue at the 99th percentile, a pre-specified secondary metric, gives a difference of +$0.09, t CI [+$0.02, +$0.16], bootstrap CI [+$0.02, +$0.17]. The ship decision is due Friday and the test cannot be extended. Which conclusion does the evidence support?
MCQ-38A messaging app A/B tests a new notification copy, randomized at the user level with 8,000 users per arm. The analyst computes open rate over message-level rows: about 16 messages per user, so 128,000 rows per arm. The within-user intra-cluster correlation of the open indicator is 0.20. The message-level analysis reports a 1.2 percentage-point lift with a standard error of 0.375 pp, t = 3.2, p = 0.0014. What does the analysis clustered at the user level give?
MCQ-34A feed-ranking change is randomised across 12,000 users, 6,000 per arm, and each user contributes roughly 9 logged sessions over four weeks, 108,000 sessions in total. Three tests of the same session-level click-through difference come back: - Shuffle all 108,000 session labels and recompute the session-level difference, 10,000 draws: p = 0.004 - Shuffle the 12,000 user labels, each user carrying all of that user's sessions, 10,000 draws: p = 0.29 - Analytic test treating the 108,000 sessions as independent units: p = 0.006 Which result does the design support?
MCQ-5A B2B analytics vendor tests a redesigned shared dashboard. The feature is enabled per account: every seat in a treated account loads the new dashboard. The team instead randomises at the session level, so within one account some sessions load the new dashboard and others the old one. Over two weeks they log 744,000 sessions across 3,100 accounts (about 30 seats per account, 4 sessions per seat per week). The session-level analysis reports +0.9% weekly active usage with a 95% interval of +0.6% to +1.2%. A rerun that randomises and clusters at the account level reports +2.6% with a 95% interval of +0.4% to +4.8%. Which conclusion should the review accept?
MCQ-14A food-delivery marketplace tests a new batching policy with a switchback: 30-minute slots, policies alternating slot by slot, 14 days, 672 slots, analysed at slot level. Couriers and orders share one marketplace, so couriers cannot be split into isolated arms. Trips dispatched under one slot's policy routinely complete during the following slot. The pre-registered analysis plan specifies a 10-minute washout at the start of each slot to let the previous policy's in-flight trips drain, and names deliveries per courier-hour over the last 20 minutes of each slot as the primary estimand. On all 30 minutes of each slot the new policy shows +1.1% deliveries per courier-hour (95% CI -0.4% to +2.6%); on the last 20 minutes only it shows +4.7% (95% CI +2.9% to +6.5%). Which conclusion should the team report?
MCQ-6A delivery marketplace tests a dispatch rule that sends each order to a nearby courier. A four-week user-level test randomises 500,000 users to treatment and 500,000 to control while the courier fleet is held fixed. Treatment orders per user rise 6.0% against the pre-period; control orders per user fall 2.0% against the same pre-period. A switchback that turned the rule on and off hourly across 40 cities over eight weeks measured +1.1% orders per user. Which figure should the rollout forecast use?
MCQ-22A subscription team shipped 11 experiments over the year. Each readout was positive, and the quarterly report sums them to +8.6% revenue. A 5% holdout, randomized at the start of the year and excluded from every launch, ended the year +9.4% above its starting revenue, while the treated population ended +11.5% above its starting revenue. Which number should the annual report carry as the year's accountable effect?
MCQ-23A payments team is ramping a new fraud-scoring service. The plan is 50% of traffic for 3 days, then 100%. At 50%, p95 latency is 120 ms and error rate 0.2%, both inside the test's bounds. In the first hour at 100%, p95 latency reaches 410 ms and the fraud-scoring queue depth crosses 1,000; the service sheds load and 2% of payment attempts fail for 40 minutes. There is no holdout at 100% and no rollback trigger between 50% and 100%. What should the team do next?
MCQ-24A team's randomised experiment (200,000 users, 50/50 split) measured a +2.1% relative lift in 30-day retention from a new onboarding flow. An observational comparison of users who adopted the flow on their own against those who did not shows +20.4%. Leadership wants a single number for the planning model. Which analysis best determines whether the gap is selection or context?
MCQ-20A team gates every experiment on week-one sessions, which it uses as a surrogate for 12-month retention. Before shipping a notification-frequency increase, it back-tests the surrogate on 45 completed experiments where both metrics were observed: | Change type | Experiments | Surrogate sign matched 12-month retention sign | | --- | --- | --- | | Content ranking | 22 | 20 | | Performance | 14 | 13 | | Notification and interruption | 9 | 4 | The notification change is ready to ship. Which conclusion does the back-test support?
MCQ-16A team estimates the effect of a job-training program on annual earnings, using random assignment to a recruitment call as an instrument for enrollment. The call raised enrollment by 0.20 (SE 0.02, first-stage F = 100) and raised earnings by $1,600 (SE $400), giving a 2SLS estimate of $8,000. The call also paid every recipient a $500 stipend whether or not they enrolled. What does the $8,000 estimate most likely represent?
MCQ-17Suppose a loyalty program gives free shipping to customers who reach 1,000 points in a quarter. The benefit is applied automatically only when the customer has a linked payment card. Among customers just above 1,000 points, 70% have a linked card and receive free shipping; among those just below, 10% receive it through a manual override. The jump in next-quarter spend at 1,000 points is +$3.00. What is the effect of free shipping on next-quarter spend for customers who receive it because they crossed 1,000 points?
MCQ-18A subscription company evaluates a new priority-support add-on. Analysts match 4,000 treated users to 4,000 controls on tenure, weekly sessions, plan tier and region. After matching, every standardised mean difference is at or below 0.04, and the reported effect is a 22% relative retention lift at 12 months (95% CI 1.14-1.30). Two facts sit alongside the result: 1,100 of 5,100 treated users (21.6%) fell outside common support and were dropped, and their median tenure was 2 months against 19 months in the matched sample; and a sensitivity analysis reports that an unmeasured confounder would need a risk ratio of about 1.5 with both the add-on and retention to shift the lower confidence bound to 1.0. The employer-paid flag was never collected. Which conclusion do these numbers support?
MCQ-15A grocery chain pilots a new delivery service in Canadian stores starting March 1; US stores are the control. Weekly orders per store: Canada (Jan 800, Feb 840, Mar 1,000, Apr 1,040; US) Jan 1,200, Feb 1,200, Mar 1,240, Apr 1,280. The same window a year earlier: Canada 760→800, US 1,160→1,160. Which conclusion is correct?
MCQ-29A team ships a new query index behind an experiment. The analysis plan registers a two-sided test of p99 query latency at α = 0.05, with write error rate as a guardrail. The readout reports z = 1.81 on latency (two-sided p = 0.070) and, in a footnote, a one-sided p = 0.035; the guardrail moved the wrong way at z = 2.17 (two-sided p = 0.030). The team proposes to launch on the one-sided latency result. What should the review conclude?
MCQ-35A team has 2,000 metabolite features and wants a ranked shortlist to take into a follow-up replication study. Each follow-up costs about a week of bench time, so the budget covers a few dozen candidates; a false lead wastes a week, and a missed true signal costs the paper. Which analysis plan should the team use?
MCQ-9A team is reviewing an A/B test of a new recommendation model before launch. The primary metric, sessions with a click, is up 3.2% relative with a 95% CI of [1.1%, 5.3%]. Two guardrails were pre-registered: p95 page latency with a non-inferiority bound of +50 ms, observed at +38 ms with a 95% CI of [-5 ms, +92 ms]; and error rate with a bound of +0.1 pp, observed at +0.02 pp with a 95% CI of [-0.03 pp, +0.07 pp]. What should the review decide?
MCQ-1A checkout team registered revenue per session as the primary metric for a two-week test, powered at 80% to detect a 1.5% relative move, with checkout error rate and p95 latency as guardrails and nine secondaries that included add-to-cart rate. At day 14 the readout is: revenue per session +0.3% (95% CI -0.8% to +1.4%), add-to-cart rate +2.1% (p = 0.02), checkout error rate +0.1 pp and p95 latency +3 ms, both inside their registered bounds. A seven-day pilot on 5% of traffic had read revenue per session +2.4%. What should the review do?
MCQ-90A checkout experiment ran 600,000 sessions per arm. Control converted at 3.00% and treatment at 3.07%: an absolute lift of 0.07 pp (2.3% relative), two-sided p = 0.025, 95% CI on the absolute lift [0.01 pp, 0.13 pp]. The change adds 80 ms to checkout, and the pre-registered bar for accepting that cost is a lower confidence bound above +0.20 pp absolute. Which statement should the readout carry?
MCQ-58A team fits a Lasso logistic regression (glmnet, R 4.3) on 12,000 rows and 40 candidate features, choosing λ by 10-fold cross-validation at λ.min. The fit keeps five features nonzero: sessions/week, support contacts, feature A adoption, feature B adoption and discount depth. They publish these as "the five drivers of churn". A reviewer asks how stable the selection is, so the team refits on 500 bootstrap resamples. Retention: sessions/week 96%, support contacts 91%, feature A 47%, feature B 44%, discount depth 39%. Feature A and feature B correlate at r = 0.93, and in 91% of resamples exactly one of that pair is selected, never both; no other pair exceeds |r| = 0.3. Which conclusion does the evidence support?
MCQ-59A team fits an OLS regression of delivery time in minutes on distance in km and package weight in kg across 4,000 orders. Overall R² = 0.61 and the residual standard error is 8.2 min. Residuals vs fitted spread roughly ±3 min at a fitted value of 20 min and ±19 min at 90 min. Cook's distance is below 0.05 for every row except three, at 1.8, 2.4 and 3.1. Refitting without those three rows moves the distance coefficient from +0.42 to −0.11 min/km. Which conclusion should the team report?
MCQ-53An analyst fits an OLS model on 12,000 customers: monthly_spend = 12.50 + 4.20*tenure_months + 0.80*plan_tier + 1.10*region_north. The 95% CI for the tenure coefficient is [3.10, 5.30]. Tenure in the training data ranges from 1 to 36 months. A retention team proposes paying every customer $10 to stay one extra month, expecting $4.20 more spend per customer. The reviewer must decide which statement to accept.
MCQ-54A subscription team regresses monthly revenue per account on a `used_chat_support` flag across 12,000 accounts and gets a coefficient of -$38. They suspect account size confounds the relationship. In the model that adds `account_size` in seats, the coefficient on `account_size` is +$40 per seat, and a regression of `account_size` on `used_chat_support` gives a slope of -1.2 seats. If account size is the only omitted confounder, what coefficient on `used_chat_support` does the two-predictor model produce?
MCQ-55A team fits an OLS regression of quarterly revenue on Sessions and Page views across 400 accounts. The two predictors correlate at r = 0.97. The output is: Sessions 0.42 (SE 0.31, p = 0.18), Page views 0.19 (SE 0.14, p = 0.17), VIF 21 for both, and the joint F test on the pair returns p = 0.002. The stakeholder asks which of the two drives revenue. What should the analyst report?
MCQ-56A retail team regresses weekly revenue on discount depth across 240 stores. Residuals fan out with store size (Breusch–Pagan p = 0.002). The fitted coefficient on discount depth is 1.84, with a classical standard error of 0.85 and an HC3 robust standard error of 1.47. The deck reports "discount depth lifts revenue, p = 0.03" and a budget reallocation is queued. What does the fit actually support?
MCQ-57A subscription product's logistic regression predicts 30-day renewal. The fitted coefficient for the annual-plan feature is 0.693 (log-odds). In the current customer base, the annual-plan segment renews at 40%. A colleague has computed the average marginal effect over the full customer base as 8.2 percentage points. The product team asks what renewal rate to expect for a comparable cohort if the feature were enabled, and what to put in the launch forecast. Which statement should the analyst report?
MCQ-60A team fits a regression of renewal on treatment, baseline usage, and their interaction on a randomised test of a new onboarding flow. usage is logins per week (range 0-7, mean 3.5). The uncentered fit gives treatment 1.8 pp (SE 0.6), usage 0.9 pp (SE 0.2), treatment:usage -0.4 pp (SE 0.15). The readout must state the effect of the new flow at the average baseline usage of 3.5 logins per week. Which value goes in the readout?
MCQ-61A retailer switches on a new loyalty program for all 300 of its stores in the same week (week 14 of a 26-week store-week panel). An analyst regresses log weekly revenue on a program indicator, store fixed effects and week fixed effects, and reports a coefficient of +0.041 (clustered SE 0.012, t = 3.4), concluding the program raised weekly revenue by 4.1%. What should the review conclude?
MCQ-62A team regresses daily revenue (thousands of dollars) on daily ad spend across 400 consecutive days. The OLS slope is 1.8 with a conventional standard error of 0.6, giving t = 3.0. The residuals have a lag-1 autocorrelation of 0.86. Which reading of this regression is defensible?
MCQ-63A retail demand-planning team built a gradient-boosted model for 28-day SKU replenishment. On a backtest over 24 monthly origins they report mean MAPE of 8.0% for the model and 7.4% for a seasonal naive baseline. For each origin they train on data up to the origin, but they build lag-7 and rolling-28 features for the 28 forecast days using the actual sales observed during those days. The model pipeline costs three engineer-weeks. Which action should the staff engineer require before adopting the model?
MCQ-64A payments team tracks settled transaction volume. This year, week 26 recorded 1,200,000 transactions over 6 trading days; week 27 recorded 840,000 over 6 trading days. In the same week of the two prior years, raw volume fell 25% and 30% week-over-week, and in both those years week 26 had 6 trading days while week 27 had 5. The on-call engineer has the raw -30% figure and is deciding whether to open an incident. Which comparison is correct?
MCQ-65An e-commerce fraud team is choosing a score cutoff for its transaction model. On a 20,000-transaction validation set containing 200 fraudulent transactions, the sweep gives: cutoff 0.2 → 1,800 alerts, 198 frauds caught; 0.4 → 700 alerts, 185 caught; 0.5 → 400 alerts, 160 caught; 0.6 → 250 alerts, 130 caught. A missed fraud costs $500 in chargebacks and investigation; reviewing a flagged legitimate transaction costs $2. The review team can clear 1,000 alerts per day and cannot add reviewers this quarter. Which cutoff should ship?
MCQ-66A retention team ranks accounts by predicted churn probability × monthly revenue and works the top of the list. The model's held-out AUC is 0.81. Its reliability table on held-out data is: | Predicted band | Accounts | Observed churn | | --- | --- | --- | | 0.90–1.00 | 1,000 | 0.90 | | 0.70–0.90 | 4,000 | 0.50 | | 0.50–0.70 | 6,000 | 0.60 | What does the table imply for the ranking?
MCQ-67A payments team trains a fraud model on a downsampled dataset in which fraud and legitimate transactions are equal in number. On a held-out set of 2,000 transactions drawn from that same 1:1 pool, at the chosen threshold the model catches 900 of the 1,000 frauds and flags 40 of the 1,000 legitimate transactions. Production traffic runs at a 0.5% fraud rate. If the team deploys at the same threshold, what precision should they expect on production traffic?
MCQ-50A payments team is deciding whether to keep `discount depth` in a conversion model. Across 50,000 sessions the Pearson correlation between discount depth and conversion is 0.04, so the feature is on the drop list. Before dropping it, an analyst bins sessions into deciles of discount depth and computes the conversion rate in each: | Decile of discount depth | 1 | 4 | 6 | 8 | 10 | | --- | --- | --- | --- | --- | --- | | Conversion rate | 2.1% | 5.6% | 6.0% | 4.2% | 2.3% | What should the team do?
MCQ-49A subscription business ran a 50/50 randomised test of a checkout redesign. Revenue per user is right-skewed, so the analyst fit OLS on log(revenue) with an arm indicator. The coefficient on the treatment arm is 0.0770 (SE 0.021). Residual variance is 0.80 in the treatment arm and 0.90 in the control arm. The analyst's slide says the redesign lifts revenue 8.0%. Finance needs a mean-scale number for the annual plan. Which figure should go on the slide?
MCQ-68A quarterly revenue readout joined 1.2M order rows to a customer dimension table and returned 1.6M rows, with the total 34% above the finance ledger. The same failure has now hit three readouts this quarter, each against a different dimension table. The team has to stop the class of error before the next readout. Which choice holds up?
MCQ-93A weekly order-value readout moved the day a promotions table was joined onto order-level facts: 50,000 orders worth 1,250,000 in revenue came back as 54,000 rows worth 1,410,000, and average order value read 26.11 against 25.00 the week before. Promotions is keyed by (order_id, promo_code) and 4,000 orders carry two codes. Which statement should the review accept?
MCQ-69A triage dashboard runs this query against the `tickets` table to size two queues: ```sql select count(*) as total, count(distinct assignee) as distinct_assignees, count(*) filter (where assignee <> 'ana') as not_ana, count(*) filter (where assignee is distinct from 'ana') as distinct_from_ana from tickets; ``` The table holds six rows: | id | assignee | |----|----------| | 1 | 'ana' | | 2 | NULL | | 3 | 'bo' | | 4 | NULL | | 5 | 'ana' | | 6 | 'bo' | Which row does the query return?
MCQ-70A nightly report computes, per customer, a running total of order amounts in the order they were placed, and a rank of each order within the customer. The running total for the first order of a customer changes between runs on unchanged data, and the rank assigned to tied orders is not stable either. Two monthly reports built from the same table disagreed by about $9,000. Which rule should the team adopt for the window functions?
MCQ-71A subscription product's analytics team is reconciling week-2 retention for the cohort of 12 users who signed up in the week of 3 March (week 0 = 3–9 March). Each user's active weeks, counted from signup, are: | user | weeks with at least one event | |---|---| | u1 | 0, 1, 2, 3 | | u2 | 0, 1, 2 | | u3 | 0, 1, 3 | | u4 | 0, 1, 2 | | u5 | 0, 1, 2, 4 | | u6 | 0, 1, 3 | | u7 | 0, 2, 3 | | u8 | 0, 1, 4 | | u9 | 0, 1, 3 | | u10 | 0, 2 | | u11 | 0, 3 | | u12 | 0, 1 | A second cohort of 8 users signed up in the week of 24 March; 2 of them have an event in their week 2, which is still in progress. The team defines week-2 retention as the share of the cohort with at least one event during week 2 exactly. Which figure belongs in the table?
MCQ-72An events table has one row per event with user_id, device_id and occurred_at. For user 42 the events are 09:00 on phone, 09:30 on laptop, 10:00 on laptop, 10:45 on phone and 11:00 on phone. A session is a run of consecutive events for the same user where each gap to the previous event is at most 30 minutes. Which grouping does a correct sessionisation produce for user 42?
MCQ-73`raw_events` stores one row per ingestion attempt, with `event_id`, `event_type`, `occurred_at` and `ingested_at`. The mobile SDK retries a failed POST up to five times with backoff, so every attempt for the same logical event carries the same `event_id` and `occurred_at` but a fresh `ingested_at`, and all attempts land within 90 seconds of the first. A nightly backfill job re-emits events it failed to deliver, again with the same `event_id` and `occurred_at`, two to four days after the original. Yesterday the report counted 41,300 purchase rows covering 39,700 distinct `event_id`s; of the 1,600 excess rows, 1,100 are SDK retries and 500 are backfill re-emits. An engineer rewrites the purchase report as: ```sql select count(*) from raw_events r where r.event_type = 'purchase' and not exists ( select 1 from raw_events e where e.event_id = r.event_id and e.ingested_at < r.ingested_at and e.ingested_at >= r.ingested_at - interval '1 hour' ); ``` What purchase count does this query return for yesterday's data?
MCQ-74A nightly dashboard query over a 120M-row `orders` table, partitioned by month on `ordered_at` (48 partitions of roughly 2.5M rows), takes 11 minutes. The plan reads all 48 partitions, aggregates 120M rows by `customer_id`, then applies `having min(ordered_at) >= date '2026-01-01'`, keeping only customers whose earliest order falls in 2026. The aggregation node accounts for 40 s of the 11 minutes; the rest is partition reads. The team needs the same result set in far less time. Which change achieves that?
MCQ-75A payments team keeps one row per event in `funnel_events (user_id, step, occurred_at)` for a four-step checkout funnel. A legacy deep link lets some users open a later step directly, and a query that counts each step independently reports 104% conversion from the second step to the third. For the weekly review the team needs, for each step, the share of users who entered at the first step and reached that step in order within a week. Which query design should they ship?
MCQ-76`fct_orders(order_id, customer_id, ordered_at, amount)` holds February 2024 orders for four customers. `dim_customer` is a Type 2 dimension with half-open validity ranges `[valid_from, valid_to)`: | customer_id | plan | valid_from | valid_to | | --- | --- | --- | --- | | C1 | Basic | 2024-01-01 | 2024-03-01 | | C1 | Enterprise | 2024-03-01 | 9999-12-31 | | C2 | Enterprise | 2024-01-01 | 9999-12-31 | | C3 | Basic | 2024-01-01 | 9999-12-31 | | C4 | Basic | 2024-01-01 | 2024-02-15 | | C4 | Enterprise | 2024-02-15 | 9999-12-31 | February orders: C1 $60,000 on 2024-02-10; C2 $40,000 on 2024-02-14; C3 $25,000 on 2024-02-20; C4 $30,000 on 2024-02-05 and $50,000 on 2024-02-22. A point-in-time join: each order matched to the dimension version whose validity range contains its timestamp: reports February revenue by plan as:
MCQ-77A weekly report query on `events`: Parquet, partitioned by day on `event_date`, 400 partitions, 2.1 TB total, about 5.3 GB per partition: runs 6 min 40 s, and the plan reports 2.1 TB scanned. The query filters `where event_ts >= timestamp '2026-08-01 00:00:00' and event_ts < timestamp '2026-08-08 00:00:00'`. Which change should you make first?
MCQ-78A weekly Pro-plan revenue report joins fct_order (one row per order: order_date, customer_id, amount) to dim_subscription (one row per customer per plan period: customer_id, plan, valid_from, valid_to) on customer_id alone, keeps plan = 'Pro', and sums amount. For the week of 3 March the 2,300 orders in the fact table total 138,000 and were all placed while the customer's plan was Pro, yet the report prints 414,000 across 6,900 rows: customers hold two to five Pro periods each, several have changed plan since, and 1,300 of the orders carry the same 59.99 flat fee. Finance holds to its 138,000. What fixes the report?
MCQ-79A nightly reconciliation job runs two statements inside one transaction against the primary and expects the two sums to match: SELECT sum(amount) FROM payments WHERE created_at < '2024-06-02'; SELECT sum(amount) FROM orders WHERE created_at < '2024-06-02'; The payments statement returns 4,000,000 at 02:00:00.100; the orders statement returns 4,240,000 at 02:00:00.700. At 02:00:00.400 the loader committed a single transaction holding 12 orders totalling 240,000 and their 12 matching payments, also 240,000, every row stamped created_at 2024-06-01 23:59:12 by the loader's own clock. The connection uses the server default, READ COMMITTED. The report it writes says 1 June payments are 240,000 short. Which explanation of the two totals is correct?
MCQ-80A fraud team's PostgreSQL query finds accounts within three hops of a flagged account: three self-joins over a transfers table of 40M edges, returning 12k accounts in 900 ms. A new requirement asks for the entire connected component containing a flagged account, at whatever depth. A recursive CTE over the same edge list ran 40 minutes before it was cancelled, and the three-hop query must keep its sub-second latency. What should the team do?
MCQ-81A weekly active accounts figure of 184,402 was published on 2026-08-31 from query revision a1f39c2 and metric definition v4. On 2026-09-01 definition v5 changed the account eligibility window, and on 2026-09-02 a backfill rewrote events from 2026-07-15 onward. Re-running the same query text and code today returns 179,880. The dashboard reads the live events table and definitions are edited in place. Which change makes the published 184,402 reproducible?
MCQ-92A streaming service ingests 100M distinct user IDs per day and must publish an hourly distinct-user count to a dashboard. The dashboard's stated tolerance is ±1% of the true count, and each worker has a 256 MB memory budget. Which structure meets both constraints?
MCQ-94An alerting pipeline looks for the smallest score cutoff t in [0, 1] at which a window's alert count meets its 300-alert budget; each evaluation is a 40 s aggregation query and alert count has been confirmed non-increasing in t. Two cutoffs are already measured: t = 0.20 returns 3,100 alerts, t = 0.60 returns 40. The team wants the smallest cutoff that meets the budget pinned down to a cutoff tolerance of 0.01. Which probe and evaluation count should they plan for?
MCQ-95A payments service needs the top 3 accounts by spend from a stream it can read only once, holding at most 3 entries in memory. It uses a bounded min-heap of size 3: push until full, then for each later item replace the heap's minimum only when the new spend is larger. The stream arrives as (account, spend): A:50, B:20, C:80, D:35, E:90, F:10. What does the heap hold after the stream ends?
MCQ-96An hourly job emits a rolling 7-day distinct count of user IDs from a raw event stream. Each run re-reads all 7 days of events and takes 50 minutes, overrunning the hour. The count must be exact, the team rejected approximate sketches, and the window advances by exactly one hour per run. Which change addresses the cause?
MCQ-97A subscription service stores one row per plan period a customer held, and the rows overlap in practice: an upgrade opens the next plan before the old one closes, and a free trial runs inside the first paid period. The churn feature `active_days` is the number of days covered by at least one row. For one customer the rows are half-open ranges [start, end) measured in days since signup, where end - start is the row's length: | row | start | end | | --- | --- | --- | | A | 6 | 12 | | B | 40 | 45 | | C | 0 | 10 | | D | 45 | 60 | | E | 2 | 4 | What value should the job write for active_days on this customer?
MCQ-98A dedup job over 1.2M customer records matches pairs at a 0.85 similarity threshold, producing 940,000 edges, then groups records by transitive closure of that graph. The largest component holds 412,000 records; the next largest holds 9. Every edge inside the big component is a match on a shared free-mail domain, edge scores run 0.86–0.99, and no two records in it share a name, phone number or postal address. What is the right read of this result?
MCQ-82A nightly pricing stage computes one fee per row for 10 million rows (12 columns, including `amount` and `plan_code`) by calling `df.apply(fee, axis=1)`, and the stage takes 21 minutes. A profile of it puts 84% of samples inside pandas' per-row Series construction and label lookup and 5% inside the arithmetic of `fee`. The `amount` column carries 9.6 million distinct values and `plan_code` carries 12. The fee is a function of those two columns only. Which change leaves the least of that 21 minutes?
MCQ-83An analyst joins a 48,120-row `orders` frame to a `customers` dimension with `on="customer_id"`, `how="left"` and `validate="many_to_one"`. `customers` holds 50,000 rows but only 47,300 distinct `customer_id` values: 2,700 ids appear twice, once as the current record and once as a superseded one. What does the merge do?
MCQ-84A nightly job on pandas 2.2 (copy-on-write left at its default, off) caps large orders before the finance dashboard reads the table: ```python orders = pd.read_parquet("orders.parquet") # 1.2M rows, amount is int64 big = orders[orders["amount"] > 1000] big["amount"] = 1000 orders.to_parquet("orders.parquet") ``` The job exits 0 and logs one SettingWithCopyWarning. The next morning the dashboard still reports a maximum amount of 48,500, and the rewritten file still holds the original amounts. The file must keep all 1.2M rows. What is going on, and what fixes it?
MCQ-85A 20-million-row frame is loaded with four columns, measured with deep memory introspection: session_id is object at 4.1 GB and holds 19.8 million distinct values; country is object at 3.6 GB and holds 190 distinct values; device is object at 1.2 GB and holds 12 distinct values; amount is float64 at 0.4 GB. The job must run tonight and the team can make exactly one change. Which change frees the most memory?
MCQ-86A nightly report over a 40 GB events file used to build a list of every row and was killed by the OOM killer at about 80% completion. It was rewritten to stream: ```python def rows(path): with open(path) as fh: for line in fh: yield line.rstrip("\n").split(",") events = rows("events.csv") # 12,000,000 lines total = sum(float(e[1]) for e in events) peak = max(float(e[1]) for e in events) print(total, peak) ``` The job now runs in constant memory. What happens when it reaches the `peak` line?
MCQ-87An analysis service loads each run's parameters from YAML into a dict and calls `run_analysis(**params)`. Inside, the significance level is read as `params.get('significance', 0.05)`. The YAML for 40 runs set `alpha: 0.01`, so every readout was computed at 0.05 and shipped before anyone noticed. The team wants the next change to make a mismatch between the keys a run's YAML provides and the keys the analysis reads surface on the first run instead of shipping a default. Which change does that?
MCQ-88An analysis pipeline runs setup(); body(); teardown() as three separate calls and writes the run manifest only after body() returns. Last quarter 37 of 400 runs raised inside body(): each skipped teardown() and left a 110 GB scratch table behind, about 4 TB in total, and the audit lists 363 runs with none of the failures. Which change makes the audit show all 400 runs with their outcome and leaves no scratch table behind?
MCQ-89A Python 3.12 collector loads a 1.5 GB in-memory index at startup, then fetches 4,000 small JSON documents (about 2 KB each) through a synchronous SDK that has no async client. Run sequentially it takes 160 s; mean response latency is 40 ms and the box's 8 cores never exceed 12% total utilisation. An 8-process version dies partway through with no Python traceback. Which change is most likely to finish the run in about 20 s?
MCQ-100A nightly job reports the top 10 products by revenue for yesterday. The events table is partitioned by day and holds 800M rows for the month at 250 bytes/row (200 GB); yesterday's partition is 6.7 GB. The warehouse scans at 3 GB/s and the link to the Python job runs at 120 MB/s. The job currently pulls the whole month and groups in pandas, taking about 28 minutes. The team needs it under 10 seconds. Which change should they make?