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
Amazon logo
Amazon
Medium
Software Engineer

Describe achievements, ambiguity, conflict, efficiency, challenges

Describe achievements, ambiguity, conflict, efficiency, challenges Behavioral Technical Screen — Multi-part Prompt Context: You are interviewing for a...

Behavioral & Leadership
2
0
30 people solved
Jul 16, 2025
Meta logo
Meta
Medium
Software Engineer

Implement range-sum tree and sort merged lists

Implement range-sum tree and sort merged lists 1) Given a binary tree whose nodes store integer values, and two integers low and high defining an incl...

Coding & Algorithms
4
0
38 people solved
Jul 16, 2025
Citadel logo
Citadel
Medium
Software Engineer

Solve two DS&A optimization problems

Problem 1 — Maximize alternating-sum over four array partitions: Given an integer array arr[1..n] (1-based). Choose indices a, b, c with 1 ≤ a ≤ b ≤ c...

Coding & Algorithms
8
0
130 people solved
Jul 16, 2025
Morgan Stanley logo
Morgan Stanley
Medium
Software Engineer

Count decodings of a digit string

Count decodings of a digit string You are given a non-empty digit string s consisting of characters '0'–'9' and a mapping where 1->'a', 2->'b', ..., 2...

Coding & Algorithms
3
0
37 people solved
Jul 16, 2025
TikTok logo
TikTok
Medium
Software Engineer

Parse chemical formula with multipliers

Parse chemical formula with multipliers Given a string representing a chemical formula, parse it and return the total count of each element. The formu...

Coding & Algorithms
3
0
34 people solved
Jul 16, 2025
Apple logo
Apple
Medium
Data Scientist

Implement sparse vector dot product and cosine similarity

Sparse Vector Class Implement a SparseVector class for high-dimensional vectors where most entries are zero. Representation Assume each vector has: - ...

Coding & Algorithms
6
0
56 people solved
Jul 15, 2025
Meta logo
Meta
Medium
Software Engineer

Maximize number with one digit swap

Maximize number with one digit swap Given a non-negative integer n (as an int or string), perform at most one swap of two digits to produce the maximu...

Coding & Algorithms
2
0
30 people solved
Jul 15, 2025
Affirm logo
Affirm
Medium
Software Engineer

Implement and debug event filtering in Python

You are given a list of event dictionaries with keys: id (str), type (str), ts (int, seconds since epoch), payload (dict). Implement filter_events(eve...

Data Manipulation (SQL/Python)
1
0
5 people solved
Jul 15, 2025
Amazon logo
Amazon
Medium
Software Engineer

Brainstorm a business problem approach

Brainstorm a business problem approach Analytics & Experimentation Brainstorm (Scenario Provided) Context You are evaluating a feature proposal for a ...

Analytics & Experimentation
4
0
42 people solved
Jul 15, 2025
Amazon logo
Amazon
Medium
Software Engineer

Design 2D DP on a DAG

Design 2D DP on a DAG Given a directed acyclic graph G(V, E) with N nodes, M edges, a designated source s, and an integer L, design a 2D dynamic progr...

Coding & Algorithms
6
0
54 people solved
Jul 15, 2025
SoFi logo
SoFi
Medium
Software Engineer

Design a key-value store with getLast

Design a key-value store with getLast Design and implement an in-memory key–value store with this API: add(key, value), get(key), remove(key), and get...

Coding & Algorithms
11
0
82 people solved
Jul 15, 2025
Meta logo
Meta
Medium
Software Engineer

Implement weighted random index picker

Implement weighted random index picker Design a class WeightedPicker that is initialized with an array of positive integer weights w and supports pick...

Coding & Algorithms
2
0
24 people solved
Jul 15, 2025
Uber logo
Uber
Medium
Software Engineer

Implement uniform sampling in squares

Implement uniform sampling in squares Implement a class Square representing an axis-aligned square on the 2D plane that supports sampling a uniformly ...

Coding & Algorithms
6
0
75 people solved
Jul 15, 2025
Google logo
Google
Medium
Software Engineer

Decide string transform with directional tokens and walls

Decide string transform with directional tokens and walls You are given two equal-length strings start and target of length n, each consisting only of...

Coding & Algorithms
4
0
59 people solved
Jul 15, 2025
DoorDash logo
DoorDash
Medium
Software Engineer

Debug and refactor a legacy module

Given a legacy module named DasherPicker and a failing test suite, systematically debug and refactor the code while following a provided review checkl...

Coding & Algorithms
40
0
310 people solved
Jul 15, 2025
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
Palantir logo
Palantir
Medium
Software Engineer

Group employees by shared interests

Given N employees, each with an integer id and a set of interests (strings), write an algorithm to find all employees who share at least one common in...

Coding & Algorithms
17
0
185 people solved
Jul 15, 2025
Meta logo
Meta
Medium
Software Engineer

Solve two string algorithm tasks

Solve two string algorithm tasks Answer both parts. A) Parentheses correction: Given a string s consisting only of '(' and ')', output the minimum num...

Coding & Algorithms
3
0
25 people solved
Jul 15, 2025
TikTok logo
TikTok
Medium
Data Engineer

Explain a SQL query result

Given two tables and a specific SQL query, precisely explain the expected result set: which rows are returned, what each column contains, how joins/fi...

Data Manipulation (SQL/Python)
1
0
10 people solved
Jul 15, 2025
TikTok logo
TikTok
Medium
Software Engineer

Check if two-group seating is possible

Check if two-group seating is possible Given an undirected graph represented as an adjacency list where adj[i] lists the indices of guests who know gu...

Coding & Algorithms
2
0
26 people solved
Jul 15, 2025