Tech Interview Questions

Practice 9,160+ 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.2k Questions 486 Companies08.11.2026
Showing 20 results
Role
DoorDash logo
DoorDash
Medium
Software Engineer

Compute nearest dashmart and busiest assignments

Compute nearest dashmart and busiest assignments You are given an m x n grid of characters where 'D' marks a dashmart, 'X' marks an impassable cell, a...

Coding & Algorithms
7
0
75 people solved
Jul 17, 2025
Meta logo
Meta
Medium
Software Engineer

Implement string sum and weighted city picker

Implement string sum and weighted city picker Part A — Add two numbers represented as strings: Given two non‑negative integers provided as decimal str...

Coding & Algorithms
3
0
36 people solved
Jul 17, 2025
IXL Learning logo
IXL Learning
Medium
Software Engineer

Identify and prevent code-breaking inputs

Identify and prevent code-breaking inputs Identify inputs and scenarios that could break your implementation and explain how you would prevent them. C...

Coding & Algorithms
5
0
56 people solved
Jul 17, 2025
IXL Learning logo
IXL Learning
Medium
Software Engineer

Solve snake game, peak search, and task scheduling

Solve snake game, peak search, and task scheduling 1) Design a grid-based snake simulation that supports move(direction) operations on a W×H board. Th...

Coding & Algorithms
4
0
73 people solved
Jul 17, 2025
TikTok logo
TikTok
Medium
Software Engineer

Explain Java DI, AOP, and transactions

Explain how dependency injection and AOP proxies are implemented in a modern Java framework such as Spring: bean lifecycle (creation, post-processing,...

Coding & Algorithms
2
0
18 people solved
Jul 17, 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
Veeva Systems logo
Veeva Systems
Medium
Software Engineer

Compute build order from dependencies

Compute build order from dependencies You are given a directed graph represented as a mapping where each key X maps to a list of tasks that depend on ...

Coding & Algorithms
2
0
41 people solved
Jul 16, 2025
Optiver logo
Optiver
Medium
Software Engineer

Detect currency arbitrage with costs

You are given a K×K matrix R of currency exchange rates where R[i][j] is the amount of currency j obtainable for one unit of currency i, and R[i][i] =...

Coding & Algorithms
36
0
261 people solved
Jul 16, 2025
Airbnb logo
Airbnb
Medium
Software Engineer

Design refundable transaction ledger and prioritization rules

Design and implement a transaction ledger that ingests a stream of records where each record is either a payment or a refund. Each payment has {id, us...

Coding & Algorithms
32
0
298 people solved
Jul 16, 2025
Samsara logo
Samsara
Medium
Software Engineer

Implement Markdown-to-HTML parser

Implement a function that converts a plain-text string into HTML supporting only these features: ( 1) Paragraphs: two or more consecutive newline char...

Coding & Algorithms
16
0
189 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
J.P. Morgan logo
J.P. Morgan
Medium
Software Engineer

Group anagrams and count string in grid

Part 1 — Group Anagrams: Given an array of strings, group together strings that are anagrams of one another and output both the grouped lists and the ...

Coding & Algorithms
4
0
35 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
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

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

Reconstruct a tree from two traversals

Reconstruct a tree from two traversals Given two arrays representing the preorder and inorder traversals of a binary tree with unique values, reconstr...

Coding & Algorithms
4
0
45 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
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