Practice for the Delta Air Lines interview with these recently asked interview questions.
| Question | Topic | Difficulty | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
SQL | Easy | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Delta Airlines is analyzing how passengers travel across its domestic network. The analytics team wants to understand which routes are most commonly flown out of each airport, and how long these popular journeys usually take. You’re working as a data analyst at Delta Airlines, and you’re provided with a table Write a SQL query to return the top 5 most frequent flight routes for each origin, ordered first by frequency descending, and then (for ties) by average journey duration ascending. Notes:
Schema:Input:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Column | Type |
|---|---|
| flight_id | INTEGER |
| origin | VARCHAR |
| destination | VARCHAR |
| departure_time | DATETIME |
| arrival_time | DATETIME |
Output:
| Column | Type |
|---|---|
| origin | VARCHAR |
| destination | VARCHAR |
| route_frequency | INTEGER |
| avg_duration_minutes | DATETIME |
flights| flight_id | origin | destination | departure_time | arrival_time |
|---|---|---|---|---|
| 1 | JFK | LAX | 2025-11-19 08:00 | 2025-11-19 11:30 |
| 2 | JFK | LAX | 2025-11-19 14:00 | 2025-11-19 17:40 |
| 3 | JFK | ORD | 2025-11-19 09:00 | 2025-11-19 10:45 |
| 4 | JFK | ORD | 2025-11-20 09:00 | 2025-11-20 10:42 |
| 5 | JFK | MIA | 2025-11-19 12:00 | 2025-11-19 15:00 |
| 6 | JFK | MIA | 2025-11-20 12:00 | 2025-11-20 14:55 |
| 7 | LAX | SFO | 2025-11-19 07:00 | 2025-11-19 08:25 |
| 8 | LAX | SFO | 2025-11-19 16:00 | 2025-11-19 17:20 |
| 9 | LAX | SEA | 2025-11-19 06:00 | 2025-11-19 08:40 |
| 10 | LAX | SEA | 2025-11-20 06:00 | 2025-11-20 08:35 |
| origin | destination | route_frequency | avg_duration_minutes |
|---|---|---|---|
| JFK | LAX | 2 | 210 |
| JFK | ORD | 2 | 103 |
| JFK | MIA | 2 | 172 |
| LAX | SFO | 2 | 82 |
| LAX | SEA | 2 | 157 |
Explanation:
From each origin (JFK, LAX), the query returns the top 5 most frequent destination routes. Since each origin has only two routes in this dataset, they are all included. For routes with the same frequency, sorting is done by increasing average duration.
SQL | Easy | |
Machine Learning | Medium | |
Statistics | Medium | |
SQL | Hard | |
Machine Learning | Medium | |
Python | Easy | |
Deep Learning | Hard | |
SQL | Medium | |
Statistics | Easy | |
Machine Learning | Hard |
Check your skills...
How prepared are you for working at Delta Air Lines?
Most data science positions fall under different position titles depending on the actual role.
From the graph we can see that on average the Data Scientist role pays the most with a $145,000 base salary while the Business Analyst role on average pays the least with a $72,000 base salary.
Discussion & Interview Experiences