Data Scientist Data Manipulation (SQL/Python) Interview Questions
Practice 550 real Data Manipulation (SQL/Python) interview questions for Data Scientist roles. From companies including Meta, Amazon, TikTok, Capital One, DoorDash.

"I got asked a hardcore MCM DP question and I saw it on PracHub as well. Solved that question in 5 minutes. Without PracHub I doubt I could solve it in 5 hours. Though somehow didn't get hired, perhaps I guess I solved it too fast? /s"

"Believe me i'm a student here jn US. Recently interviewed for MSFT. They asked me exact question from PracHub. I saw it the night before and ignored it cause why waste time on random sites. I legit wanna go back and redo this whole thing if I had chance. Not saying will work for everyone but there is certainly some merit to that website. And i'm gonna use it in future prep from now on like lc tagged"

"10 years of experience but never worked at a top company. PracHub's senior-level questions helped me break into FAANG at 35. Age is just a number."

"I was skeptical about the 'real questions' claim, so I put it to the test. I searched for the exact question I got grilled on at my last Meta onsite... and it was right there. Word for word."

"Got a Google recruiter call on Monday, interview on Friday. Crammed PracHub for 4 days. Passed every round. This platform is a miracle worker."

"I've used LC, Glassdoor, and random Discords. Nothing comes close to the accuracy here. The questions are actually current — that's what got me. Felt like I had a cheat sheet during the interview."

"The solution quality is insane. It covers approach, edge cases, time complexity, follow-ups. Nothing else comes close."

"Legit the only resource you need. TC went from 180k -> 350k. Just memorize the top 50 for your target company and you're golden."

"PracHub Premium for one month cost me the price of two coffees a week. It landed me a $280K+ starting offer."

"Literally just signed a $600k offer. I only had 2 weeks to prep, so I focused entirely on the company-tagged lists here. If you're targeting L5+, don't overthink it."

"Coaches and bootcamp prep courses cost around $200-300 but PracHub Premium is actually less than a Netflix subscription. And it landed me a $178K offer."

"I honestly don't know how you guys gather so many real interview questions. It's almost scary. I walked into my Amazon loop and recognized 3 out of 4 problems from your database."

"Discovered PracHub 10 days before my interview. By day 5, I stopped being nervous. By interview day, I was actually excited to show what I knew."

"I recently cleared Uber interviews (strong hire in the design round) and all the questions were present in prachub."
"The search is what sold me. I typed in a really niche DP problem I got asked last year and it actually came up, full breakdown and everything. These guys are clearly updating it constantly."
Analyze document collaboration patterns
You are given two CSV files and asked to analyze collaboration behavior on documents. File 1: document_activity.csv Each row is a document view event....
Write SQL for rankings, state, and aggregations
This question evaluates a candidate's competency in SQL data manipulation, covering ranking/top-N queries, aggregations and percentage calculations, t...
Find top buyer in earliest 10-year window
This question evaluates proficiency in data manipulation and analytical querying with SQL/Python, emphasizing date-based windowing, join operations, a...
Compute this-year spend share of last-year whales
This question evaluates proficiency in data manipulation and analytics engineering, specifically SQL and Python skills for aggregations, joins, calend...
Compute a Seven-Day Rolling Average
You are analyzing daily product metrics for the Fetch mobile app. Table daily_metric_values | Column | Type | Description | |---|---:|---| | metric_da...
Convert Dates to Calendar Quarter Labels in SQL/Python
Transactions +----+-----------+ | id | trans_dt | +----+-----------+ | 1 | 20230115 | | 2 | 20230402 | | 3 | 20230930 | | 4 | 20231201 | +---...
Compute Cohort Retention Rate
You are given two tables: - users(user_id BIGINT, signup_ts TIMESTAMP) — one row per user. - user_activity(user_id BIGINT, activity_ts TIMESTAMP, even...
Calculate Order Request Metrics
You are working with DoorDash order and delivery-request data. Write SQL to answer the questions below. Tables: 1. orders - order_id BIGINT, primary k...
Compute ad revenue metrics by geography in SQL
You work on a marketplace app that shows shop ads. You are given the following tables. Assumptions - All timestamps are stored in UTC. - “Revenue” is ...
Design MapReduce and Spark jobs
Big data systems: (a) Explain Hadoop’s fault tolerance (HDFS replication, task re-execution) and why MapReduce includes shuffling and sorting; in a wo...
Design a data platform enablement
Design a pragmatic data‑platform enablement for a mid‑tier retail bank migrating to cloud under PII and data‑residency constraints. Describe the targe...
Analyze Multiple-Account Users in SQL
This question evaluates a data scientist's ability to perform SQL-level user- and account-level aggregation, grouping, and NULL-aware filtering to com...
Find recommended friend pairs by shared listening
Problem (SQL) You work on a music app and want to recommend new friend connections based on listening similarity. Tables Assume the following schemas:...
Find top-paid employee per department
Tables Assume the company stores employee compensation by department assignment. employee_dept_salary - employee_id INT - employee_name VARCHAR - depa...
Campaign Efficiency Metrics and Below-Average CTR
Campaign Efficiency Metrics and Below-Average CTR You are given an ad_campaigns table with one row per campaign: | Column | Type | Meaning | | --- | -...
Compute time-spent percentage by app category
You work on Oculus app engagement analytics. Tables user_activity - user_id (BIGINT) - date (DATE) — day of activity (assume UTC) - app_id (INT) - ses...
Design an idempotent SQL ETL for late data
You own the daily_user_metrics fact table. Build an idempotent, rerunnable ETL that can be triggered for any date D and correctly handles duplicates, ...
Solve window-function SQL without joins
You must use only window functions (no JOINs). CTEs are allowed. Given the schemas and tiny samples below, write SQL for each sub-question and explain...
Write SQL for noisy A/B launch metrics
PostgreSQL. Today is 2025-09-01. You’re given the following schema and toy samples: users(user_id INT, country TEXT, signup_date DATE, marketing_chann...
Write rolling-window SQL over weekly cohorts
You have two tables: users and transactions. Write a single SQL query (use CTEs) to produce, for each calendar week and user, weekly_revenue, a 4-week...