Skip to content

Internship interviews

Data science internship interviews: SQL, statistics, modeling and case rounds

A data science internship interview can draw on four skill areas, which we group as a SQL query, a statistics or probability problem, a question about modeling and metrics, and a product or case discussion. Below is one worked problem for each, the query checked on a sample table and the probability problems recomputed by code, so you can practice the habit of each round and not a list of questions.

Your first hour with George Li (60 minutes by video, $250) ends with a written plan within one working day.

Book your first hour ($250)

The round types programs state

Program pages say little about what a data science round contains. In our programs dataset, 6 AI-family programs state a technical, assessment, behavioral or case step, and the wording is below. Capital One’s page, for one, states that its interviews include job fit, behavioral and case interviews, by program.

Steps stated by AI-family programs that name a technical, assessment, behavioral or case step
ProgramSteps as the page states them
Capital OneA recruiter reviews your experience and contacts you, then Some programs require an online assessment, then Job fit, behavioral and case interviews, by program, then The recruiter reaches out with a decision
Dropbox90 minute CodeSignal assessment, then Recruiter interview, 20 minutes, then Virtual technical interviews, then Final round interview
IBMFind a requisition on the IBM careers search, then Apply to roles whose basic qualifications you meet, then Assessment if the requisition has one, then Recruiter contact for next steps
NetflixApply on the job site once a role is open, then Take-home assessment, then Two to three rounds of interviews
RampTechnical assessment, then Phone screen, then Evaluation interviews in open book format
Two SigmaApplication, then Technical interview, then Behavioral interview

The Bureau of Labor Statistics describes data scientists as an occupation with a typical entry education of bachelor's degree and projected growth of 34.6% over 2025-2035. The grouping on this page, SQL, statistics, modeling and a case, is our own, chosen because those are the skills most data science postings name. Read your posting and match the rounds to it.

The SQL round: a worked query

A SQL round may give you a small table and ask for a result. The skills are joins, grouping and filtering, and window functions for ranking within a group. The PostgreSQL documentation covers each: its query chapter on joins, grouping and set operations, and its tutorial on window functions.

Here is a table named submissions, with three columns: student, problem and score.

The sample table, submissions
studentproblemscore
Anap180
Anap290
Anap370
Benp160
Benp2100
Camp195
Deep150
Deep255
Deep360
Deep465

Task: for each student with at least two submissions, find the number of submissions and the average score, rounded to one decimal, highest average first, with ties broken by name.

Query: SELECT student, COUNT(*) AS n, ROUND(AVG(score), 1) AS avg_score FROM submissions GROUP BY student HAVING COUNT(*) >= 2 ORDER BY avg_score DESC, student;

The result, computed from the sample rows
studentnavg_score
Ana380.0
Ben280.0
Dee457.5
  • WHERE filters rows before grouping and HAVING filters groups after it. That is why the filter on the count sits in HAVING, and why Cam, with one submission, is left out.
  • Rounding the average, and adding the name to the ORDER BY, are the details an interviewer notices. Without the second sort key, tied averages could come out in either order.
  • To keep each student’s best row and not a summary, use a window function: ROW_NUMBER() OVER (PARTITION BY student ORDER BY score DESC), then keep the rows numbered 1.
The best row for each student, by the window function, computed from the sample rows
studentbest score
Ana90
Ben100
Cam95
Dee65

Say aloud what each clause does before you type it, and state an assumption when the table is unclear, such as whether a student can appear with a missing score.

Statistics and probability: worked problems

These rounds ask for a probability you can count, or a conditional or updated probability. The method is the same as in the quant guides: define the sample space, count what matters, divide and check. Here are three original problems from our checked bank, with answers a separate program recomputes.

Problem 1. A fair coin is flipped 6 times. Given that at least 4 of the flips are heads, what is the probability that the first flip is heads? Give a fraction in lowest terms.

Show the answer and the working

Answer: 8/11

  1. Outcomes with at least 4 heads: C(6,4) + C(6,5) + C(6,6) = 15 + 6 + 1 = 22.
  2. Among them, those with a head first need at least 3 heads in the last 5 flips: C(5,3) + C(5,4) + C(5,5) = 10 + 5 + 1 = 16.
  3. The conditional probability is 16/22 = 8/11.

Problem 2. One of two coins is chosen at random with equal chances. The first coin is fair. The second lands heads with probability 3/4. The chosen coin is flipped 3 times and lands heads every time. What is the probability that it is the second coin? Give a fraction in lowest terms.

Show the answer and the working

Answer: 27/35

  1. Chance of 3 heads from the second coin: (3/4)^3 = 27/64. From the fair coin: (1/2)^3 = 8/64.
  2. The two coins start equally likely, so the posterior is (27/64) / (27/64 + 8/64).
  3. That is 27/35.

Problem 3. Two cards are dealt from a standard 52-card deck, which holds 4 aces. Given that at least one of the two cards is an ace, what is the probability that both are aces? Give a fraction in lowest terms.

Show the answer and the working

Answer: 1/33

  1. Count unordered pairs of cards: C(52, 2) = 1326.
  2. Pairs with no ace: C(48, 2) = 1128, so pairs with at least one ace: 1326 - 1128 = 198.
  3. Pairs with two aces: C(4, 2) = 6, and each of them has at least one ace.
  4. The conditional probability is 6/198 = 1/33.

For more of this kind, read probability for quant interviews. A habit worth building is saying what you condition on and what you update, as in the second problem, where the answer weighs two coins by how likely each was before and how well each explains three heads.

Modeling and metrics

Modeling questions ask you to choose a model and a metric and explain the choice. For classification, read the worked precision and recall problems on the machine learning interview topics page. For a number you predict, the scikit-learn metrics guide lists regression metrics, among them mean absolute error and mean squared error. They treat large mistakes differently, and the table shows how.

Two error metrics on the same errors, computed
ErrorsMean absolute errorMean squared error
2, -1, 3, -224.50
2, -1, 3, -2, 10 (one large miss added)3.6023.60

One large error moved the mean absolute error from 2 to 3.60 and the mean squared error from 4.50 to 23.60, a far larger jump, because squaring makes a big miss count for more. So the choice depends on whether a big miss is worse than several small ones. State that reason, then say how you would check the result on rows the model did not see.

The product or case round, in general terms

A case round gives you a situation, such as a number that moved, and asks how you would reason about it. The details differ, so practice a way of thinking and not a bank of cases. Our own structure has five steps:

  1. Clarify the goal: what decision does the answer feed, and who makes it?
  2. Define the metric: what exactly is counted, over what period and for whom?
  3. List explanations: split by group, time and source, and say which you would check first and why.
  4. Name the data you would pull for each explanation and what result would change your mind.
  5. Give a recommendation with a caveat, and say what you would do next if you were wrong.

Practice by taking a number from your own project, such as a rate that changed between two versions, and talking through the five steps aloud for ten minutes. Thinking out loud covers the habit.

The stages you may pass through

Processes differ by employer, so treat this as a typical order and not a fact about any one of them, and ask the recruiter what your process holds. Many data roles run in three stages.

Typical stages of a data role process, and what to prepare for each
StageWhat it usually isHow to prepare
A recruiter callA short phone conversation about your background and why you want the role, often with questions drawn from your resumeBe able to explain each project on your resume in two sentences, and say why this employer and this kind of work
A technical screenOne or two live sessions or a take-home task, on SQL, coding, statistics or a mix, with the mix set by the employerAsk the recruiter which skills it covers, then practice those under a timer and out loud
A final set of interviewsSeveral conversations in a row, often with current data scientists, each on a different area, sometimes with a manager or someone from another teamPrepare one example for each of the five families below and keep your energy up across the day

Some employers run fewer rounds for an internship, or skip a stage. Ask the recruiter how many rounds to expect and when you will hear back, because the posting and the recruiter are the only sources for your case.

Five families of question, and how to practice each

Almost everything a data science interviewer asks falls into five families. The prompts below are our own practice prompts, written for this page, so you can check your answers against your own work.

The five families, what each tests and a way to practice
FamilyWhat it testsA practice prompt of oursHow to practice
Coding and SQLWhether you can work with data and write correct code under time pressure, including queries and basic data structuresFrom a table of visits with a user and a date, count the distinct users in each weekSolve problems on a practice site, write them on paper or a plain editor, and say your reasoning aloud as you go
StatisticsWhether you understand the concepts you would apply, such as a p-value, a confidence interval and a test of two groupsExplain in three sentences what a p-value tells you and what it does notReview the definitions, then explain each to a friend with no background, and practice reading a small experiment result
Machine learningWhether you can choose a model, a metric and a way to check it, and explain the trade-offsA model has higher accuracy than another but misses most of the rare class; which would you ship and whyWork through free course material, then rebuild one model from a project and be ready to explain every choice
Product senseWhether you can turn a data question into a decision for a team, with metrics and experimentsA feature launched and a usage number fell; list three causes and the first thing you would checkPick a product you use, name five metrics for it and describe how you would test a change
BehavioralWhether you can describe past work, handle a setback and fit the team, in plain storiesDescribe a project that took a wrong turn and what you changedWrite one short story for each theme and line them up with the posting’s main requirements

Spend the most time on the families your target stage tests. If the posting names SQL or statistics, drill those first. For behavioral questions, align your stories to the top qualifications in the posting, and if the employer publishes its values, have one example ready for each of them. Our thinking out loud guide covers the habit of narrating your reasoning.

Three ways to practice, and what each leaves out

  • On your own. It is the necessary first step, because you learn the material and find your gaps. It cannot reproduce a stranger’s follow-up questions or the pressure of a clock, and it gives no outside feedback.
  • With peers. A friend or classmate can run a mock interview for free, and your career center may offer practice sessions. The drawbacks are that their feedback may be inaccurate, they may not know how your target employers interview, and a plan can slip when someone does not turn up.
  • With someone who has interviewed candidates. This is where you meet follow-up questions, time pressure and feedback from a person who knows what a good answer sounds like. In a session George plays that role: he gives you a table and a question, asks you to explain each step and presses on the assumption you skipped.

Mix the three. Start alone, test yourself with peers, and use an outside reader where the feedback matters most, once you have a good answer to improve.

Questions

What rounds are in a data science internship interview?

Program pages state few details. A round can draw on a SQL query, a statistics or probability problem, modeling and metrics, or a product or case discussion, so read your posting and ask the recruiter.

What is the difference between WHERE and HAVING in SQL?

WHERE filters rows before grouping, and HAVING filters groups after it. A condition on a count belongs in HAVING.

Which error metric should I use for a prediction?

Mean absolute error treats all misses alike, and mean squared error counts large misses more. Choose by whether one big miss is worse than several small ones.

How a session helps

In an hour ($250) George can give you a table and a question, ask you to explain each clause as you write it and press on the assumption you skipped. You write every word and every line of code yourself. Your first purchase is refundable for unused time within 7 days. See the data science internship guide and the data scientists career page for the field.

Want help with your own applications? See internship interview coaching, a career coach for college internships, or resume review for internships.

Start with one hour

  • Your first purchase is refundable for unused time within 7 days. Nothing renews. Refund terms