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 486 Companies08.11.2026
Showing 20 results
Role
HubSpot logo
HubSpot
Medium
Software Engineer

Design a bank with scheduled payments and merges

Design an in-memory banking service that supports the following operations: ( 1) CreateAccount(accountId), ( 2) Deposit(accountId, amount), ( 3) Trans...

Coding & Algorithms
23
0
175 people solved
Sep 6, 2025
Google logo
Google
Medium
Software Engineer

Find largest subset sharing a common digit

You are given a list of two-digit integers (each from 10 to 99, inclusive). You want to select as many numbers as possible in one selection such that:...

Coding & Algorithms
6
0
70 people solved
Sep 5, 2025
Meta logo
Meta
Medium
Machine Learning Engineer Locked

Solve sampling and streaming tasks

This question evaluates algorithmic problem-solving, data structure design, probabilistic reasoning for weighted random selection, sliding-window stri...

Coding & Algorithms
1
0
29 people solved
Sep 4, 2025
Jane Street logo
Jane Street
Hard
Software Engineer

Decode an Encrypted Paragraph Tree

Decode an Encrypted Paragraph Tree A document is stored as a tree of paragraphs. Each node holds a paragraph text — a string of lowercase English lett...

Coding & Algorithms
0
0
18 people solved
Sep 14, 2022
Optiver logo
Optiver
Medium
Software Engineer

Maximum Currency Conversion Rate

Maximum Currency Conversion Rate You are given N currency exchange rate pairs. Each pair is a triple (from_currency, to_currency, rate), meaning that ...

Coding & Algorithms
0
0
9 people solved
Jan 31, 2025
TikTok logo
TikTok
Easy
Data Scientist Locked

How would you measure misinformation impact and recommendation bias?

This question evaluates a data scientist's analytics and experimentation competencies — including metric and diagnostic design, sampling and labeling ...

Analytics & Experimentation
4
0
64 people solved
Aug 30, 2025
Google logo
Google
Medium
Software EngineerIntern

Solve Grid and Counting Problems

A software engineering intern phone screen included two coding tasks: 1. Count islands in a grid Given an m x n grid of characters where '1' re...

Coding & Algorithms
1
0
13 people solved
Jan 25, 2025
Two Sigma logo
Two Sigma
Medium
Software Engineer

Maximize Capital by Completing at Most k Projects

A startup has an initial amount of capital w and is choosing which projects to take on before an important funding deadline. There are n candidate pro...

Coding & Algorithms
1
0
10 people solved
Aug 26, 2025
Morgan Stanley logo
Morgan Stanley
Medium
Data Scientist Locked

Answer basic probability and statistics questions

This question evaluates core probability and statistics competencies, including interpretation of Poisson rate parameters from PMF shapes, identificat...

Machine Learning
4
0
46 people solved
Aug 23, 2025
Meta logo
Meta
Medium
Data Scientist

Compute SHOP spend share and model performance

You work on ads measurement. Advertisers can drive users to either Facebook Shop ('SHOP') or their own website ('WEBSITE'). After an ad is shown, you ...

Data Manipulation (SQL/Python)
7
0
62 people solved
Aug 21, 2025
Meta logo
Meta
Medium
Data Scientist Locked

Define and estimate prevalence of unhealthy users

This question evaluates a data scientist's ability to operationalize an "unhealthy user" metric and compute its prevalence from session duration and d...

Analytics & Experimentation
3
0
36 people solved
Aug 17, 2025
Meta logo
Meta
Hard
Data Scientist Locked

Test if social users are more engaged

This question evaluates a data scientist's competencies in observational analytics, engagement metric selection, cohort construction for overlapping b...

Analytics & Experimentation
1
0
27 people solved
Aug 17, 2025
Worldquant logo
Worldquant
Medium
Data Scientist

Update Box Probabilities After Drawing Red Balls

Three boxes are equally likely to be selected: - Box A contains two red balls. - Box B contains one red and one blue ball. - Box C contains two blue b...

Statistics & Math
0
0
2 people solved
Jan 5, 2025
Worldquant logo
Worldquant
Medium
Data Scientist

Derive the Long-Run Sex Ratio Under a Stopping Rule

Assume each child is independently equally likely to be a girl or a boy. Every family continues having children until its first boy, then stops. For a...

Statistics & Math
0
0
2 people solved
Jan 5, 2025
Tesla logo
Tesla
Medium
Software Engineer

Solve classic array, graph, and parsing problems

Implement and analyze solutions to the following independent tasks: 1) Expression evaluator: Given a string s of digits, '+', '-', '*', '/', and space...

Coding & Algorithms
9
0
67 people solved
Aug 14, 2025
Meta logo
Meta
Medium
Software Engineer

Implement basic expression evaluator

Implement a function to evaluate a string expression containing non-negative integers, '+', '-', '*', '/', and spaces. Multiplication and division hav...

Coding & Algorithms
4
0
30 people solved
Aug 14, 2025
Anthropic logo
Anthropic
Medium
Software Engineer

Design file deduplication across nested directories

Design and implement a file deduplication tool that, given a root directory, identifies groups of duplicate files. Requirements: traverse nested direc...

Coding & Algorithms
21
0
203 people solved
Aug 14, 2025
Roblox logo
Roblox
Medium
Software Engineer

Find largest digit-sum bucket size

You are given two integers low and high (inclusive). Define s(x) as the sum of the decimal digits of x. For every integer x in [low, high], place x in...

Coding & Algorithms
14
0
156 people solved
Aug 13, 2025
Anthropic logo
Anthropic
Medium
Software Engineer

Detect n-length consecutive sequences

Given an unsorted collection of integers and a parameter n > 0, determine whether there exists a set of n distinct integers that form a run of consecu...

Coding & Algorithms
23
0
216 people solved
Aug 13, 2025
Anthropic logo
Anthropic
Medium
Software Engineer

Compute matrix trace and support updates

Given an n x n integer matrix M, implement a function trace (M) that returns the sum of its main diagonal. Follow-ups: (a) If you receive q point upda...

Coding & Algorithms
15
0
185 people solved
Aug 13, 2025