Ace your next data science interview

Join our data science newsletter and solve a few interview questions a week
No spam and one click unsubscribe.

How It Works

Join premium today

Get access to detailed solutions for all questions

Sign up for premium today

In-depth solutions from these companies hiring data scientists

Sample Data Science Interview Question

Sign up for our free newsletter to receive the answer to the question

Given a table of users and a table of comments called user_comments, write a SQL query to generate a histogam of number of comments per user in the month of January 2019. Assume bin buckets intervals of one.

`users` table
columns type
id int
name varchar
joined_at datetime
city_id int
device int

`user_comments` table

columns type
user_id int
body text
created_at datetime

Here are some of our happy customers!

Quan L.
Data Analyst at Facebook

I found the questions really helpful when I was interviewing. They were actually relevant, from companies that I applied to, and so a few of the questions actually showed up and I was well prepared to answer them.

Learn more...
angie h.
Angie H.
Data Analyst at Addepar

Interview Query is great! The solutions are really well written and the concepts in the sql questions were surprisingly repeated a couple times in all of my interviews.

Learn more...
James G.
Senior Machine Learning Engineer

I used these questions when I was studying while looking for my next job. They're super comprehensive, made the questions easy to understand, and I felt well-prepped going into my interviews.

Learn more...
We use cookies to personalise content and ads, to provide social media features and to analyse our traffic. You consent to our cookies if you continue to use our website. 🙅 disagree ✅ consent