Skip to content
Tech Interview Prep

Real Interview Questions for the Data Engineer at Meta

New

Practice MCQs

Answers count toward the Data Engineer and overall leaderboards; your latest answer to each question is the one that counts.

20 questions · Flow follows Relevance until this set has a learning order.

MCQ-1A Meta Data Engineer screen gives 90 seconds for 'Tell me about yourself', then 35 minutes deep-diving whichever project the answer names; the team owns real-time ingestion. Record: 2 years of nightly Oracle ETL at a bank, last touched 2020; 4 years on a 9-person retailer team owning the exactly-once sink and schema registry of a 2B-events/day Kafka→Spark pipeline, whose 24h→5min freshness gain came from a platform team's change; 2 of 11 tables in a migration. Which answer fits?
MCQ-2`checkouts(id, user_id, due_date, return_date)` has one row per loan, `return_date` NULL while the book is out. Alice's loans are due 03-01 (returned 02-20), 03-05 (returned 03-05) and 03-10 (still out); Bob's 03-02 (returned 03-09) and 03-04 (returned 03-01); Cara's 03-07 (returned 03-07) and 03-08 (returned 03-06). Counting each user's loans not returned before the due date, a return on the due date itself counts, which counts are right?
MCQ-3A pooled-ride service ships `ride_riders(request_id, rider_id, seat_no)` with `PRIMARY KEY (request_id, seat_no)` and foreign keys to `ride_requests` and `riders`. Monday's loader inserts, in order: (9001,1,42), (9001,2,77), (9001,3,91), (9001,2,77) again, (9002,1,77), (9002,1,42), (9002,2,77). Which account of the load and of the query `SELECT request_id, count(*) FROM ride_riders GROUP BY 1` is right?
MCQ-4`fact_sales` holds one row per sale and `dim_book(book_id, author_id)` one row per title. Author 7 has five titles, two of which sold (3 sale rows); author 9 has four titles, one of which sold 40 copies. The report must list every author with at least five published titles, sold or not, and runs `SELECT b.author_id FROM fact_sales f JOIN dim_book b ON b.book_id = f.book_id GROUP BY b.author_id HAVING COUNT(*) >= 5`. Which account of its output and the change it needs is right?
MCQ-5Postgres 16, session `TimeZone = 'America/New_York'`; finance defines a registration day as the UTC date of `registered_at`. `users`: u1 03-01 02:00Z, u2 03-02 14:00Z, u3 03-03 23:50Z. `orders`: u1 03-01 23:00Z $100, u1 03-02 01:00Z $300, u2 03-02 22:00Z $200, u3 03-03 23:55Z $50, u3 03-04 08:00Z $150, and a guest order 03-02 12:00Z $200 whose `user_id` is not in `users`. Which result gives each customer's own same-UTC-day revenue as a share of all order revenue?
MCQ-6A job counts ride requests in 15-minute event-time tumbling windows and emits each window 5 minutes after it ends; client retries can deliver the same `ride_id` twice. Events: `r1` 10:00:00, `r2` 10:14:59, `r3` 10:15:00, `r3` again at 10:15:00, `r4` 10:29:59, `r5` 10:30:00, and `r6` stamped 10:14:30 that reaches the job at 10:18. What does the job emit for the 10:00, 10:15 and 10:30 windows?
MCQ-7`users(id, inviter_id)` records who invited each user and `payments(id, user_id, amount)` has one row per payment. Inviter A invited u1 (payments 5, 10, 15) and u2 (100, 100); B invited u3 (50, 50) and u4 (50, 50); C invited u5 (90). Ranked by the average payment per item, one payment row each, across everyone an inviter invited, which ranking and averages are right?
MCQ-8`transactions(txn_id, customer_id, payment_type, amount_cents)` has one row per order. Customer c1 has two card orders, c5 two cash orders, and c3 one card and one wallet order. The team needs total order value and unique customer count per payment type, sorted by payment type in descending order. Which query returns that report?
MCQ-9Four stores report comments. A: `Great coffee` once, `Slow service` three times. B: `Great coffee` once, `Slow service` twice, `Friendly staff` once. C: `Great coffee` once, `Slow service` once, `Friendly staff` twice. D: `Great coffee` once, `Slow service` twice, `Friendly staff` once. Count each comment at most once per store, return the comment present in the most stores, and break ties by ascending alphabetical order. Which comment does the report return?
MCQ-10`workshops(year, workshop_id)` holds one row per workshop held; a year with no workshop has no rows. The table contains 2014: 1, 2015: 2, 2016: 3, 2017: 4, 2019: 8, 2020: 6, 2022: 5. A report must return the largest total number of workshops across any run of consecutive years in which every year held at least one workshop. Which value and reasoning are right?
MCQ-11`fact_reel_view` has one row per view (`view_id`, `reel_id`, `viewed_at`, `watch_ms`). `dim_reel` is SCD2: reel 8842 has sk 101/audio A for [03-01 00:00, 03-10 09:00), sk 102/audio B for [03-10 09:00, 03-12 15:00), sk 103/audio C from 03-12 15:00; one view lands exactly at 03-10 09:00. A 03-13 backfill reloads 03-09–03-12 views, and product needs daily watch time by the audio at view time plus a current-audio dashboard. Which fact/dimension design and join are right?
MCQ-12`referrals(invitee_id, inviter_id, share)` is a bridge table: an invitee can be claimed by several inviters and its shares sum to 1. A invited B (1.0) and C (0.6); D also invited C (0.4); B and C each invited E (0.5); E invited F (1.0). Payments: E 200, F 100, all others 0. An inviter's downstream LTV is each descendant's payments times the product of shares on the path, summed over every path. What is A's downstream LTV?
MCQ-13A daily pipeline writes `sessions(user_id, dt, n)` from a streaming job that appends with plain `INSERT` and emits day D at 00:10 the next day, with 10 minutes of allowed lateness; dashboards read the table directly. Raw events land in `events`, deduplicated on `event_id`. On D+3, 40,000 day-D events from 4,000 users arrive from a patched SDK with their original event times. Which action makes day D correct?
MCQ-14A revenue job runs at 02:00, overwrites the `order_date = current_date - 1` partition, and must publish by 06:00. On 03-02 it published $1.2M for 03-01 against a $1.8M 7-day average; the log shows the replica's `max(updated_at)` was 03-01 21:00, and OLTP says a 21:00 bulk delete of test orders stalled replication until 09:00. It is now 09:30. Which recovery plan is right?
MCQ-15`fact_orders` is keyed on `order_id` alone and holds 40M rows. After a regional split the OLTP `orders` table reuses `order_id` per region, so 1.2M IDs now exist in two regions and the loader's upsert keeps only the last region's row; 14 dashboards read the table. The OLTP team owns `orders` and can add `region` to its CDC topic next sprint. Which rebuild plan is right?
MCQ-16`sales(customer_id, book_id, sold_at)` holds one row per book bought; the table's earliest `sold_at` is 2024-01-03 and its latest is 2024-03-28. On 01-03 the row counts are c1 3, c2 3, c3 2, c4 3, c5 3; on 03-28 they are c1 3, c2 2, c3 4, c4 3. c5's only other rows are 5 books on 02-15, and c1 also has 1 book on 02-10. Which customers does a query return that finds everyone who bought 3 or more books on both the first and the last sales day in the table?
MCQ-17App events (2B/day, `device_id`, `event_ts`, p95 arrival 5 s) must carry the cell tower the device was on at `event_ts`. Carrier telemetry is one row per connectivity interval (`device_id`, `cell_id`, `radio`, `start_ts`, `end_ts`), 400M rows/day, p95 arrival 90 min late; a handover overlaps two intervals and a disconnect leaves a gap. The troubleshooting dashboard tolerates 3 hours of staleness and the last 90 days must stay correctable. Which design is right?
MCQ-18`copies(copy_id, condition)` holds 8 rows in 'good' and 4 in 'fair'. `checkouts(copy_id, return_date, renewals)` has one row per copy: of the good copies, 4 have `return_date IS NULL` with renewals 2, 3, 4 and 5, and 4 were returned; of the fair copies, 3 are still out. A report returns the count of good copies not returned and the percentage of those copies with more than two renewals. Which count and percentage are right?
MCQ-19`sessions` has one row per session; `crashes` has one row per crash (`session_id`), so a session can repeat. For country BR, version 4.2, 7 days: day 1 has 100 sessions, 5 crashed, 6 crash rows; day 2 has 10 sessions, 2 crashed, 2 crash rows; day 3 has 1000 sessions, 10 crashed, 10 crash rows; days 4–7 have none. The daily average crash rate is the mean of daily rates on days with sessions, a day's rate = distinct crashed sessions / sessions. Which value is right?
MCQ-20A dedupe job flags listings whose titles differ, comparing word by word with `def diff(a, b): aw, bw = a.split(), b.split(); return [w for i, w in enumerate(aw) if i >= len(bw) or w != bw[i]]` on Python 3.12. It runs `diff("SKU 7 7 in stock", "sku 7 in stock")`, where the first title has a double space after `SKU`. What does the call return, and why?

Curated: · Written: · Reviewed: