Tech Interview Questions

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

Popular Interview Questions

Machine Learning Engineer + Data Scientist + Software Engineer Interview Questions

Practice the exact questions companies are asking right now.

9.0k Questions 480 Companies08.05.2026
Showing 20 results
Role
Google logo
Google
Medium
Software Engineer

Return dictionary words matching a prefix

You are given a list of strings words (a dictionary) and a string prefix. Return all words in words that start with prefix. Clarifications/constraints...

Coding & Algorithms
26
0
191 people solved
Mar 9, 2026
Upstart logo
Upstart
Medium
Software Engineer

Decrypt a twice-encrypted message using known pairs

Three people pass notes A → B → C → A. Notes are encrypted using a character-substitution cipher (a one-to-one mapping per character). You are given t...

Coding & Algorithms
6
0
105 people solved
Mar 9, 2026
Upstart logo
Upstart
Medium
Software Engineer

Reverse even numbers in a list

Given an integer array nums, remove all odd numbers and return the remaining even numbers in reverse order (preserving no other ordering constraints)....

Coding & Algorithms
13
0
151 people solved
Mar 9, 2026
Meta logo
Meta
Easy
Software Engineer

Implement an in-memory database with record locking

Implement an in-memory key–record database that supports basic CRUD on fields plus an exclusive lock per record. You are given a sequence of queries. ...

Coding & Algorithms
9
0
102 people solved
Mar 8, 2026
eBay logo
eBay
Hard
Software EngineerSenior+

Find top co-viewed products

You are given a list of user browsing sessions, where each session is a list of product IDs, a target_product, and an integer k. A product should be c...

Coding & Algorithms
4
0
35 people solved
Mar 7, 2026
Meta logo
Meta
Medium
Software Engineer

Minimum Round-Trip Flight Cost

You are planning a round trip and want to spend as little as possible on flights. You are given two integer arrays of equal length n: - departure[i] —...

Coding & Algorithms
0
0
5 people solved
Mar 6, 2026
Meta logo
Meta
Medium
Software Engineer AI

Maximum Length of a Word Selection With All Unique Characters

You are given an array of lowercase strings words. Select a subset of these words (zero or more, chosen in any order) and concatenate them. The select...

Coding & Algorithms
0
0
7 people solved
Mar 6, 2026
Google logo
Google
Medium
Software Engineer

Return Words Matching a Typed Prefix

Given words and a query prefix, return all words starting with that prefix in lexicographic order. Implement: `python def prefix_matches(words: list[s...

Coding & Algorithms
0
0
7 people solved
Mar 6, 2026
Apple logo
Apple
Medium
Software Engineer

Generate Tower of Hanoi moves

You are given n disks of different sizes stacked on peg A (largest at bottom). You have two other pegs, B and C. You may move one disk at a time, and ...

Coding & Algorithms
9
0
88 people solved
Mar 6, 2026
Meta logo
Meta
Hard
Data Scientist

Write SQL for reply-based recipient metrics

You work on a social product and are given two tables. Assumptions (use these unless you state otherwise): - All timestamps are in UTC. - A “reply” is...

Data Manipulation (SQL/Python)
47
2
437 people solved
Mar 5, 2026
Meta logo
Meta
Hard
Data Scientist

Compute High-Call Usage Rates

You are given two tables for a voice-calling product: users - user_id BIGINT - country_code STRING calls - call_id BIGINT - caller_id BIGINT - recipie...

Data Manipulation (SQL/Python)
3
0
29 people solved
Mar 4, 2026
Google logo
Google
Medium
Software Engineer Locked

Solve several coding interview problems

This set of problems evaluates proficiency in string processing and combinatorial parsing, arbitrary-precision arithmetic using string representations...

Coding & Algorithms
10
0
98 people solved
Mar 4, 2026
Uber logo
Uber
Medium
Software Engineer Locked

Find the First Unique Log

This question evaluates a candidate's ability to analyze and implement efficient data-processing and frequency-detection strategies on ordered string ...

Coding & Algorithms
3
0
48 people solved
Mar 4, 2026
Meta logo
Meta
Medium
Software Engineer

Construct a BST and read spiral order

The coding round reportedly included two algorithmic tasks: 1. Rebuild a binary search tree from a preorder sequence - You are given an array of di...

Coding & Algorithms
17
0
115 people solved
Mar 4, 2026
Amazon logo
Amazon
Medium
Software EngineerIntern

Compute Latencies and Search Grid Path

You are given two coding tasks from an internship interview. Task 1: Compute Message Latency from CSV Logs Two systems, ComputeA and ComputeB, exchang...

Coding & Algorithms
0
0
15 people solved
Mar 4, 2026
Amplitude logo
Amplitude
Medium
Software Engineer

Implement Employee Validation and Snake

This interview covered two coding tasks: 1. Employee validation - Implement a function that validates a collection of employees against a set of bu...

Coding & Algorithms
4
0
50 people solved
Mar 3, 2026
Two Sigma logo
Two Sigma
Medium
Data Scientist Locked

Evaluate a Piecewise Linear Function

This question evaluates understanding of linear interpolation, numerical reasoning with ordered 2D points, and input validation when computing values ...

Coding & Algorithms
4
0
38 people solved
Mar 3, 2026
Airbnb logo
Airbnb
Medium
Software EngineerSenior+

Parse Query Parameters Into a Map

Implement a function that parses the query portion of a GET URL and returns a map from query keys to parsed values. Input is a string that may start w...

Coding & Algorithms
2
0
17 people solved
Mar 2, 2026
Meta logo
Meta
Medium
Data Scientist Locked

Write SQL for seller and vehicle metrics

This question evaluates proficiency in SQL data manipulation, including joins, distinct counts, grouping and aggregation, filtering by date and catego...

Data Manipulation (SQL/Python)
7
0
81 people solved
Mar 2, 2026
Anthropic logo
Anthropic
Medium
Software Engineer

Implement Parallel Image Processing

Build an image-processing utility in Python using the Pillow library. You are given a collection of image file paths and an output directory. For each...

Coding & Algorithms
2
0
13 people solved
Mar 2, 2026