Coding & Algorithms Interview Questions

Practice 3,469 real Coding & Algorithms interview questions for 2026. Covers companies like Meta, Amazon, Google, Uber, and Microsoft. Real questions from actual interviews with detailed solutions — ideal for focused interview preparation. Coding & Algorithms interview questions are the single most common technical gate for software engineering roles and are used to evaluate problem framing, algorithm selection, complexity trade-offs, correctness, edge-case reasoning, and clear communication under time pressure. Expect this category to appear in early technical screens and repeatedly across onsite loops at companies that weight it heavily (notably Meta, Google, and Amazon). Interviews will test arrays and strings, trees and graphs, dynamic programming, hashing and two‑pointer techniques, and the candidate’s ability to test and optimize code in a shared editor. Prepare with timed mock interviews, practice in the same editor you’ll use live, and build a progressive schedule that moves from fundamentals to medium/hard problems; typical candidates invest several weeks to a few months of focused practice depending on seniority and target company.

3.5k Questions 368 Companies08.11.2026
Showing 20 results
Role
Uber logo
Uber
Medium
Frontend Engineer Locked

Implement a Constant-Time Random Pool

This question evaluates a candidate's ability to design and implement an efficient data structure supporting average O(1) add, remove, and uniform ran...

Coding & Algorithms
1
0
15 people solved
May 4, 2026
Uber logo
Uber
Medium
Software Engineer Locked

Implement Cache Eviction And Seat Assignment

This question evaluates understanding of data structure design and algorithmic reasoning, covering cache eviction policies (least-recently-used) and s...

Coding & Algorithms
0
0
9 people solved
May 4, 2026
Visa logo
Visa
Hard
Software EngineerSenior+ Locked

Solve Two Algorithm Challenges

These two problems evaluate algorithmic skills in array optimization and graph pathfinding: the first focuses on selecting three ordered, non-overlapp...

Coding & Algorithms
0
0
15 people solved
May 4, 2026
Google logo
Google
Hard
Software EngineerNew Grad Locked

Simulate In-Place Cellular State Updates

This question evaluates a candidate's ability to implement grid-based state transitions and manage in-place updates with strict space constraints, ass...

Coding & Algorithms
7
0
41 people solved
May 4, 2026
Tesla logo
Tesla
Medium
Data Engineer Locked

Write SQL Data Transformation Queries

This question evaluates proficiency in SQL data transformation and aggregation, testing competencies such as monthly-reset running totals, hierarchica...

Coding & Algorithms
5
0
41 people solved
May 4, 2026
DRW logo
DRW
Medium
Data Scientist

Solve movie ratings, array, release scheduler

Question This is a three-part coding screen used for a Data Scientist role at DRW. You will work through three independent array/sequence problems, ea...

Coding & Algorithms
5
0
72 people solved
Aug 4, 2025
Uber logo
Uber
Medium
Software Engineer

Perform matrix Candy Crush elimination

Question Implement a function that, given an m × n integer matrix representing colored blocks (same integers = same color), performs one round of "Can...

Coding & Algorithms
4
0
70 people solved
Aug 4, 2025
Jane Street logo
Jane Street
Easy
Machine Learning EngineerNew Grad

Marketplace Data Store: Order Matching and End-of-Day Reconciliation

Marketplace Data Store: Order Matching and End-of-Day Reconciliation You are building the core of a marketplace where sellers list individual units of...

Coding & Algorithms
0
0
14 people solved
Aug 2, 2025
Capital One logo
Capital One
Medium
Software Engineer

Implement deposit, withdraw, and transfer in a class

Problem Implement a class AccountService that supports basic money operations on accounts. Operations - deposit(accountId, amount) - withdraw(accountI...

Coding & Algorithms
11
0
105 people solved
Dec 25, 2025
Meta logo
Meta
Medium
Software Engineer

Find balanced subarray and increasing tree path

You are given two coding problems. Problem 1: Longest balanced subarray (0/1) Given an integer array nums of length n where each element is either 0 o...

Coding & Algorithms
6
0
64 people solved
Nov 2, 2025
Uber logo
Uber
Medium
Software Engineer Locked

Find possible robot positions

This question evaluates a candidate's ability to reason about grid traversal, boundary conditions, directional visibility counting, and constraint-bas...

Coding & Algorithms
5
0
99 people solved
Feb 21, 2026
Citadel logo
Citadel
Hard
Data Scientist Locked

Sort a Nearly Sorted Array

This question evaluates algorithm design and analysis skills, focusing on handling nearly-sorted arrays and reasoning about time and space complexity ...

Coding & Algorithms
6
0
67 people solved
Feb 21, 2026
Google logo
Google
Medium
Machine Learning Engineer

Implement a Web Crawler with BFS and DFS

Implement a simple web crawler in Python. You are given: - A starting URL. - A function get_links(url) -> list[str] that returns all outgoing links fr...

Coding & Algorithms
1
0
18 people solved
Dec 24, 2025
Ngrok logo
Ngrok
Medium
Software Engineer

Generate Color Feedback for a Word Guess

Generate Color Feedback for a Word Guess Given an answer string and a guess of the same length, produce one color for each guessed character: - "green...

Coding & Algorithms
0
0
4 people solved
May 1, 2026
eBay logo
eBay
Medium
Software Engineer Locked

Format Words into Fixed-Width Lines

This question evaluates proficiency in string manipulation, greedy line-packing algorithms, and attention to implementation details such as spacing di...

Coding & Algorithms
3
0
27 people solved
May 1, 2026
OpenAI logo
OpenAI
Hard
Software Engineer

Implement a Contiguous Memory Allocator with Primitive Lists

Implement a Contiguous Memory Allocator with Primitive Lists Simulate an allocator over the contiguous address range [0, capacity), initially one free...

Coding & Algorithms
1
0
14 people solved
Feb 19, 2026
LinkedIn logo
LinkedIn
Medium
Data Scientist Locked

Find index with positive suffix sums

This question evaluates array manipulation and algorithmic problem-solving skills, focusing on reasoning about cumulative (suffix) sums and time-compl...

Coding & Algorithms
4
1
97 people solved
Feb 19, 2026
Pinduoduo logo
Pinduoduo
Easy
Software Engineer

Find missing rank in a straight

You are given a list of 4 distinct characters representing card ranks from a 5-card straight (5 consecutive ranks) with exactly one rank missing. Rank...

Coding & Algorithms
6
0
46 people solved
Feb 19, 2026
Uber logo
Uber
Medium
Software Engineer Locked

Design structure for bottom-K customers by revenue

This question evaluates data structure design and algorithmic complexity for dynamic order-statistics and update operations, focusing on maintaining c...

Coding & Algorithms
7
0
81 people solved
Oct 29, 2025
Meta logo
Meta
Easy
Software Engineer Locked

Compute Range Sum Quickly

This question evaluates a candidate's understanding of range-sum queries, array preprocessing techniques and algorithmic complexity for answering mult...

Coding & Algorithms
3
0
49 people solved
Feb 18, 2026

Frequently Asked Questions

How difficult are Coding & Algorithms interview questions?
Difficulty spans a wide range: from quick easy warm-ups to multi-stage hard problems that require advanced data structures or algorithmic proofs. Most companies place a majority of live coding rounds at the medium level, with occasional hard questions used to distinguish senior candidates. Interviewers evaluate problem framing, algorithm choice, time/space complexity, clean implementation, and thoughtful testing under time pressure. Expect more conceptual depth at Google, more consistent medium-to-hard screens at Meta, and Amazon to mix coding with leadership signals. Leveling depends on role and seniority: entry-level focuses on fundamentals; senior roles emphasize design, optimizations, and tradeoffs.
Where does Coding & Algorithms appear in a typical interview loop, and which companies weight it most heavily?
Coding & Algorithms is usually the first technical hurdle: it appears in phone/online screens, followed by one or more onsite or virtual coding rounds during the loop. Typical sequences are a technical screen, two to three in-loop coding sessions, then system design or behavioral rounds. Companies that weight this category heavily include Google, Meta, and Amazon, where coding performance often determines whether you progress. Candidates commonly concentrate practice for weeks or months beforehand; most targeting large tech firms prepare intensively for 6–12 weeks, while some spend 3–6 months for deeper mastery or level changes.
How long should I prepare and how should I structure that preparation?
Plan focused, progressive practice over a realistic timeline. A practical structure is an 8–12 week block: weeks 1–2 solidify fundamentals and language fluency; weeks 3–6 target core patterns (arrays, trees, graphs, DP) with timed problem sessions and pattern tagging; weeks 7–9 emphasize mock interviews, end-to-end problem solving, and optimization tradeoffs; final weeks simulate real loops with full-length sessions and targeted weak-point drills. Candidates with less experience may extend to 12–16 weeks. Regularly review mistakes, practice communicating solutions aloud, and include at least one weekly mock interview with peer or coach feedback.
What key subtopics and patterns should I master for Coding & Algorithms interviews?
Master a consistent set of patterns and their variations: arrays and strings (two pointers, sliding window), hash maps and frequency counts, sorting and binary search, recursion and backtracking, dynamic programming, trees and traversals, graphs (BFS/DFS, shortest paths, union-find), heaps and priority queues, and greedy algorithms. Also practice complexity analysis, space-time tradeoffs, and writing bug-resistant code with tests. For higher levels, focus on amortized analysis, advanced graph algorithms, segment trees or Fenwick trees, and system-aware optimizations. Interviewers value reusable problem templates and the ability to generalize patterns to new prompts.
What are standout tips and common pitfalls to avoid in Coding & Algorithms interviews?
Start by clarifying requirements and constraints, then outline your approach before coding. Write a correct, readable baseline solution first, then iterate to improve complexity while narrating tradeoffs. Test with simple and edge cases, and handle nulls, off-by-one, and empty inputs explicitly. Communicate continuously; silence looks like confusion. Avoid premature optimization, overcomplicating solutions, or ignoring interviewer hints. Time management matters: if stuck, discuss alternate approaches and code a partial solution. Finally, practice mock interviews to reduce anxiety and build the habit of clear, structured explanations under pressure.

Explore more Coding & Algorithms interview questions

Jump straight to Coding & Algorithms questions at a specific company or for a specific role.

By company
By role