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
xAI logo
xAI
Easy
Software Engineer

Phone Keypad Predictive Text Suggestions

Phone Keypad Predictive Text Suggestions You are building the predictive-text feature for a classic 9-key phone keypad. Each digit from 2 to 9 maps to...

Coding & Algorithms
1
0
13 people solved
Jun 7, 2025
Anthropic logo
Anthropic
Hard
Software Engineer

Implement staircase printing and distributed mode/median

Problem A: Print a “staircase” pattern Implement a function that prints a staircase with n rows. Input - An integer n (n >= 1) Output - Print n lines....

Coding & Algorithms
67
0
923 people solved
Nov 19, 2025
Microsoft logo
Microsoft
Medium
Software Engineer

Merge overlapping intervals

You are given an array of intervals, where each interval is represented as a pair of integers [start, end] with start <= end. The intervals may be uns...

Coding & Algorithms
3
0
55 people solved
Nov 19, 2025
Amazon logo
Amazon
Medium
Software EngineerSenior+ Locked

Answer Leadership and Collaboration Prompts

This question evaluates leadership, collaboration, interpersonal communication, conflict resolution, adaptability, and self-reflection competencies wi...

Behavioral & Leadership
4
0
36 people solved
Nov 17, 2025
Amazon logo
Amazon
Medium
Software EngineerSenior+ Locked

Solve Shipping and Bundle-Cost Problems

This question evaluates algorithmic reasoning for scheduling and capacity planning (minimum daily shipping capacity) and combinatorial optimization wi...

Coding & Algorithms
2
0
38 people solved
Nov 17, 2025
Microsoft logo
Microsoft
Medium
Software Engineer

Find max consecutive elements with sum below target

You are given: - An integer array nums of length n, sorted in non-decreasing order. - An integer index such that 0 ≤ index < n. - An integer target. S...

Coding & Algorithms
8
0
84 people solved
Nov 17, 2025
Uber logo
Uber
Hard
Software Engineer

Check feasibility of AI course schedule

You are designing a learning path for n AI-related courses, labeled from 0 to n - 1. Some courses have prerequisites. For example, to take course b, y...

Coding & Algorithms
7
0
79 people solved
Nov 17, 2025
Optiver logo
Optiver
Hard
Software EngineerNew Grad

Cargo Order Allocation Across Departing Planes

A freight company assigns incoming shipping orders to a fixed fleet of cargo planes. You must implement the order-processing logic: decide whether eac...

Coding & Algorithms
0
0
10 people solved
Nov 16, 2025
Google logo
Google
Medium
Software Engineer

Compute minimal transfers to settle group expenses

Problem A group of friends go on a trip and share expenses. Each expense is recorded as an object: - payer (string): who paid the full amount - amount...

Coding & Algorithms
11
0
81 people solved
Nov 16, 2025
Salesforce logo
Salesforce
Medium
Software Engineer

Remove duplicates from a singly linked list

You are given the head of a singly linked list of integers. Modify the list in place so that it contains only the first occurrence of each value (i.e....

Coding & Algorithms
9
0
116 people solved
Nov 13, 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
3 people solved
Jan 5, 2025
Meta logo
Meta
Easy
Software Engineer

Design a time-versioned key-value store and find common free time

You are given two coding tasks. Task 1: Time-versioned key-value store Design an in-memory data structure that supports: - set(key, value, timestamp):...

Coding & Algorithms
4
0
32 people solved
Nov 12, 2025
WeRide logo
WeRide
Medium
Data Scientist

Design Ride-Quality Metrics and Diagnose Ratios

You are interviewing for an autonomous-driving metrics team. The team wants to measure rider experience for completed rides using trip-level data such...

Analytics & Experimentation
3
0
64 people solved
Jan 4, 2025
Pinterest logo
Pinterest
Medium
Software Engineer

Solve set equality and ad log top‑K

Problem Set (Coding) 1) Check whether two sets are equal You are given two integer arrays A and B that represent sets, except they may contain duplica...

Coding & Algorithms
19
0
197 people solved
Nov 11, 2025
Atlassian logo
Atlassian
Medium
Software Engineer Locked

Evaluate Architecture and Capacity Trade-offs

This multi-part question evaluates system architecture trade-offs, capacity and storage planning, security-aware component design, and document dedupl...

Software Engineering Fundamentals
1
0
20 people solved
Nov 10, 2025
Glean logo
Glean
Easy
Data Scientist

Compute DAU and rolling MAU with zero days

You have two tables in PostgreSQL: Tables users - user_id (STRING / INT, PK) - signup_date (DATE) logins - user_id (STRING / INT, FK → users.user_id) ...

Data Manipulation (SQL/Python)
5
0
61 people solved
Nov 10, 2025
Uber logo
Uber
Easy
Data Scientist Locked

Design metrics and A/B test for maps and ETA

This question evaluates proficiency in metrics design, causal inference, and experimentation for product and marketplace features, specifically testin...

Analytics & Experimentation
18
0
193 people solved
Nov 9, 2025
Databricks logo
Databricks
Hard
Software Engineer

Find shortest path in a Fibonacci-ordered tree

You are given a recursively-defined binary tree T(order) whose shape depends only on order (not on node values). Nodes are labeled 0..N-1 using preord...

Coding & Algorithms
20
0
153 people solved
Nov 6, 2025
Chime logo
Chime
Easy
Data Scientist

Compute early signals for user retention

You are given two tables that track signups and user transactions. Tables users - user_id (STRING, PK) — unique user - signup_ts (TIMESTAMP) — time th...

Data Manipulation (SQL/Python)
13
1
120 people solved
Nov 6, 2025
Affirm logo
Affirm
Easy
Software Engineer

Implement an LRU cache

Problem Design and implement an LRU (Least Recently Used) cache that supports the following operations in average O(1) time: - get(key) -> value: Retu...

Coding & Algorithms
10
0
89 people solved
Nov 6, 2025