Tech Interview Questions

Practice 9,555+ interview questions from top companies including Google, Meta, Amazon, and more. Filter by company, role, and category.

Popular Interview Questions

Interview Questions

Practice the exact questions companies are asking right now.

9.6k Questions 505 Companies08.05.2026
Showing 20 results
Role
TikTok logo
TikTok
Medium
Software Engineer

Write complex SQL for cohorts and retention

Given tables users(uid, created_at, country), orders(order_id, uid, amount, created_at, status), and events(uid, ts, event_type, campaign), write one ...

Data Manipulation (SQL/Python)
0
0
9 people solved
Jul 15, 2025
Pinterest logo
Pinterest
Medium
Data Scientist

Implement Function to Return First n Prime Numbers

Scenario Quick algorithm screen to gauge Python fluency. Question Implement a Python function that returns the first n prime numbers. Hints An optimiz...

Coding & Algorithms
10
0
38 people solved
Jul 12, 2025
Meta logo
Meta
Medium
Data Scientist

Expected meetings in Room 1 after random assignment

Expected Meetings in Room 1 Conditional on Being Non-empty There are N rooms and k meetings. Each meeting independently chooses a room uniformly at ra...

Analytics & Experimentation
12
0
32 people solved
Jul 12, 2025
Snapchat logo
Snapchat
Medium
Data Scientist

Monitor Friend-Request System for Quality and Abuse

Friendship +--------------+-------------+---------------------+---------------------+ | requester_id | approver_id | request_ts | approval_ts...

Data Manipulation (SQL/Python)
111
1
350 people solved
Jul 12, 2025
TikTok logo
TikTok
Medium
Data Scientist

Maximize Distinct Purchases Within Budget Constraints

Scenario Given a customer budget and a list of product prices, determine the maximum number of distinct products the customer can afford. Question Des...

Coding & Algorithms
28
0
52 people solved
Jul 12, 2025
Meta logo
Meta
Medium
Data Scientist

Analyze New Shops' Activity Compared to Existing Ones

shops +---------+------------+---------------+ | shop_id | created_at | category | +---------+------------+---------------+ | 1 | 2024-01-0...

Data Manipulation (SQL/Python)
53
0
8 people solved
Jul 12, 2025
Capital One logo
Capital One
Medium
Data Scientist

Determine Country with Most 'Sunny' Days

Weather +------------+------------+---------+ | country | date | weather | +------------+------------+---------+ | Spain | 2023-07-01 | ...

Data Manipulation (SQL/Python)
54
0
174 people solved
Jul 12, 2025
Citadel logo
Citadel
Medium
Data Scientist

Implement Infinite Fibonacci Generator Using Lazy Evaluation

Scenario Testing understanding of Python lazy evaluation and generators. Question Explain what lazy evaluation means in Python and implement a generat...

Coding & Algorithms
20
0
41 people solved
Jul 12, 2025
Point72 logo
Point72
Medium
Data Scientist

Determine Most Frequent Product Color in Carts

Scenario Online store wants to know which color of product appears most frequently in customers’ carts. Question Implement a function getMaxColor(colo...

Coding & Algorithms
30
0
100 people solved
Jul 12, 2025
Amazon logo
Amazon
Medium
Business Intelligence Engineer

Identify Frequent Actor-Director Collaborations in Film Database

FILMOGRAPHY +-------+---------+------------+ | actor | dir | date | +-------+---------+------------+ | Tom | Nolan | 2020-01-01 | | Tom ...

Data Manipulation (SQL/Python)
1
0
7 people solved
Jul 12, 2025
Meta logo
Meta
Medium
Data Scientist

Evaluate Facebook's Restaurant Recommendations Feature Effectiveness

Experiment Design: Restaurant Recommendations in Facebook News Feed Facebook is considering restaurant recommendation units inside News Feed, such as ...

Analytics & Experimentation
12
0
36 people solved
Jul 12, 2025
OneMain Financial logo
OneMain Financial
Medium
Data Scientist

Count, Return, Find, and Select in SQL Queries

orders +----------+--------------+------------+--------+ | order_id | customer_id | order_date | amount | +----------+--------------+------------+---...

Data Manipulation (SQL/Python)
78
0
197 people solved
Jul 12, 2025
Amazon logo
Amazon
Medium
Data Scientist

Implement Function to Determine Mode and Prime Numbers

Scenario Implementing utility algorithms within a data-processing library. Question Write a function that returns the mode of an integer list; if all ...

Coding & Algorithms
19
0
56 people solved
Jul 12, 2025
Amazon logo
Amazon
Medium
Business Intelligence Engineer

Calculate Weekly Event Sums from Daily Counts

EVENT_LOG +------------+------+ | event_date | cnt | +------------+------+ | 2025-05-01 | 17 | | 2025-05-02 | 12 | | 2025-05-08 | 30 | +-------...

Data Manipulation (SQL/Python)
2
0
6 people solved
Jul 12, 2025
Amazon logo
Amazon
Medium
Business Intelligence Engineer

Identify Unique Unordered City Pairs in Flight Log

FLIGHTS +----------------+---------------+ | departure_city | arrival_city | +----------------+---------------+ | NYC | LAX | | ...

Data Manipulation (SQL/Python)
3
0
2 people solved
Jul 12, 2025
Amazon logo
Amazon
Medium
Data Scientist

Design Incremental Load Process for Large Relational Table

orders_daily_load +------------+-----------+-------------+--------+ | load_date | order_id | customer_id | amount | +------------+-----------+------...

Data Manipulation (SQL/Python)
86
0
213 people solved
Jul 12, 2025
Meta logo
Meta
Medium
Data Scientist

Analyze Hashtag Follow Behavior with SQL Queries

following_behavior +------------+---------+-----------+---------------+ | date | user_id | hashtag_id| hashtag_source| +------------+---------+-...

Data Manipulation (SQL/Python)
5
0
26 people solved
Jul 12, 2025
Capital One logo
Capital One
Medium
Data Scientist

Automate Python Virtual Environment Setup on Linux Terminal

Scenario Shell script that automates Python virtual-environment setup on a Linux terminal during a tech interview Question Walk through the script lin...

Coding & Algorithms
104
0
321 people solved
Jul 12, 2025
Meta logo
Meta
Medium
Data Scientist

Expected round of first selection in repeated sampling

Random Perk Selection: Expected First Round There are 1,000 employees. Each round, 10 distinct employees are selected at random for a perk. No one can...

Analytics & Experimentation
13
0
36 people solved
Jul 12, 2025
Meta logo
Meta
Medium
Data Scientist

Calculate Recent Post Views and Reactions for Social Media

info_stream_views +---------+-----------+--------------+----------+------------+ | post_id | viewer_id | relationship | duration | ds | +-----...

Data Manipulation (SQL/Python)
87
0
320 people solved
Jul 12, 2025