Products
Features
YouTube Video Summarizer
Summarize YouTube videos
Web & PDF Highlighter
Highlight web pages & PDFs
Chat with PDF
Ask any PDF questions with AI
Ask AI Clone
Chat with your highlights & memories
Audio Transcriber
Transcribe audio files to text
Glasp Reader
Read and highlight articles
Kindle Highlight Export
Export your Kindle highlights
Idea Hatch
Hatch ideas from your highlights
Integrations
Obsidian Plugin
Notion Integration
Pocket Integration
Instapaper Integration
Medium Integration
Readwise Integration
Snipd Integration
Hypothesis Integration
Apps & Extensions
Chrome Extension
Safari Extension
Edge Add-ons
Firefox Add-ons
iOS App
Android App
Discover
Discover
Ideas
Discover new ideas and insights
Articles
Curated articles and insights
Books
Book recommendations by great minds
Posts
Essays and notes from readers
Quotes
Inspiring quotes collection
Videos
Curated videos and summaries
Explore Glasp
Glasp Newsletter
Weekly insights and updates
Glasp Talk
Interview series with great minds
Glasp Blog
Latest news and articles
Glasp Use Cases
Learn how others use Glasp
Build & Support
Glasp API
Access Glasp's API for developers
MCP Connector
Connect Glasp to Claude & ChatGPT
Community
Glasp Reddit Community
Students
Student discount and benefits
FAQs
Frequently Asked Questions
AboutPricing
DashboardLog inSign up

Data Science SQL Interview Question Walkthrough | SQL Sundays #9

64.4K views
•
June 1, 2021
by
Tina Huang
YouTube video player
Data Science SQL Interview Question Walkthrough | SQL Sundays #9

TL;DR

Walkthrough of a data science SQL interview question on Airbnb growth.

Transcript

hi welcome to another sql sunday where i go through a walkthrough of a real data science interview question let's get started all right so this question over here is growth of airbnb so let's read the question estimate the growth of airbnb each year using the number of hosts registered as the growth metric the rate of growth is calculated by taking... Read More

Key Insights

  • The video walks through a real data science interview question focusing on estimating Airbnb's growth using SQL queries.
  • The growth metric is calculated using the number of hosts registered each year, with a specific formula provided.
  • The speaker emphasizes the importance of understanding the data structure, highlighting that only unique hosts are considered.
  • A detailed SQL query is constructed, involving a common table expression (CTE) and a self-join to calculate growth rates.
  • The speaker suggests an alternative solution using window functions, inviting viewers to explore its efficiency.
  • An announcement is made about a new SQL course designed to prepare for tech interviews with mock interviews and guided walkthroughs.
  • The course offers a comprehensive guide on SQL interview preparation and includes practical exercises with real datasets.
  • The video is part of a broader SQL Sundays series aimed at helping viewers improve their SQL skills for data science roles.

Install to Summarize YouTube Videos and Get Transcripts

Explore YouTube Video Summarizer or Get YouTube Transcript Extractor

Questions & Answers

Q: What is the main focus of the SQL interview question discussed?

The SQL interview question focuses on estimating the growth of Airbnb by analyzing the number of hosts registered each year. The growth rate is calculated using a specific formula involving the difference in host numbers between consecutive years, divided by the previous year's host count, and expressed as a percentage.

Q: What assumptions are made in the analysis?

The analysis assumes that the dataset contains only unique hosts, meaning there are no duplicates. Additionally, it assumes that there is no growth rate for the first year due to the lack of a previous year's data. The speaker contemplates how to handle this scenario, considering leaving it blank or removing the row.

Q: How is the SQL query constructed to solve the problem?

The SQL query is constructed using a common table expression (CTE) to extract the year and number of hosts. A self-join is then performed to compare the number of hosts between consecutive years. The growth rate is calculated using the specified formula, and the results are ordered by year.

Q: What alternative solution is suggested for the problem?

The speaker suggests using window functions as an alternative solution to the self-join approach. Viewers are invited to explore how window functions could be applied to calculate the growth rate and consider whether this method would be more efficient than the self-join approach presented in the video.

Q: What is the SQL course announced in the video about?

The announced SQL course is designed to prepare individuals for tech and data science interviews. It includes 10 mock interviews with guided walkthroughs and coaching. The course provides practical exercises with real datasets and aims to help learners master SQL skills necessary for passing technical interviews.

Q: How does the course differ from the free content on the channel?

The course offers a structured, step-by-step guide on SQL interview preparation, unlike the free content. It includes 10 full mock interviews with an interviewer providing feedback, which is not available in the free SQL Sundays series. The course also offers direct support from the instructor for any questions.

Q: What additional resources are provided with the course?

The course provides resources such as data and SQL scripts for interview questions, allowing learners to practice with real datasets. It also includes instructions for installing and using database management tools like pgAdmin, enhancing the practical learning experience.

Q: What value does the course aim to provide to learners?

The course aims to equip learners with the skills and confidence needed to excel in SQL portions of data science interviews. By completing the mock interviews and exercises, learners should feel well-prepared for real interviews, having experienced scenarios similar to actual interview settings.

Summary & Key Takeaways

  • This video provides a detailed walkthrough of a SQL interview question focused on estimating Airbnb's growth by analyzing host registration data. The speaker constructs a SQL query using CTEs and self-joins to calculate growth rates and discusses potential optimizations.

  • The speaker explains the assumptions made during the analysis, such as considering only unique hosts and handling the first year's growth rate. An alternative approach using window functions is suggested, encouraging viewers to explore its efficiency.

  • An announcement introduces a new SQL course for tech interviews, offering mock interviews and practical exercises. The course aims to equip learners with the skills needed to excel in SQL portions of data science interviews, providing direct support and feedback.


Read in Other Languages (beta)

English

Share This Summary 📚

Summarize YouTube Videos and Get Video Transcripts with 1-Click

Download browser extensions on:

Try YouTube Summary with ChatGPT & Claude or YouTube Transcript Generator

Explore More Summaries from Tina Huang 📚

How I Became a Data Scientist | Computer Science Job Search Part 2 thumbnail
How I Became a Data Scientist | Computer Science Job Search Part 2
Tina Huang
How To Self Study AI FAST thumbnail
How To Self Study AI FAST
Tina Huang
What Are the New Features of Claude 4 Models? thumbnail
What Are the New Features of Claude 4 Models?
Tina Huang
Will AI Replace Programmers? thumbnail
Will AI Replace Programmers?
Tina Huang
How to Use Science-Based Strategies for Better Learning thumbnail
How to Use Science-Based Strategies for Better Learning
Tina Huang
How to Use Google AI Studio for Maximum Productivity thumbnail
How to Use Google AI Studio for Maximum Productivity
Tina Huang

Summarize YouTube Videos and Get Video Transcripts with 1-Click

Download browser extensions on:

Try YouTube Summary with ChatGPT & Claude or YouTube Transcript Generator

Apps & Extensions

  • Chrome Extension
  • Safari Extension
  • Edge Add-ons
  • Firefox Add-ons
  • iOS App
  • Android App

Key Features

  • YouTube Video Summarizer
  • Web & PDF Summarizer
  • Web & PDF Highlighter
  • Chat with PDF
  • Ask AI Clone
  • Audio Transcriber
  • Glasp Reader
  • Kindle Highlight Export
  • Idea Hatch

Integrations

  • Obsidian Plugin
  • Notion Integration
  • Pocket Integration
  • Instapaper Integration
  • Medium Integration
  • Readwise Integration
  • Snipd Integration
  • Hypothesis Integration

More Features

  • APIs
  • MCP Connector
  • Blog & Post
  • Embed Links
  • Image Highlight
  • Personality Test
  • Quote Shots

Company

  • About us
  • Blog
  • Community
  • FAQs
  • Job Board
  • Newsletter
  • Pricing
Terms

•

Privacy

•

Guidelines

© 2026 Glasp Inc. All rights reserved.