Coding & Algorithms Interview Questions
Practice 3,013 real Coding & Algorithms interview questions for 2026. Coding & Algorithms interview questions for top tech firms like Meta, Amazon, Google, Uber, and TikTok — real questions from actual interviews with detailed solutions — to power your interview preparation. This collection is sharply focused on algorithmic patterns (arrays, strings, sliding windows, trees/graphs, dynamic programming, greedy, two-pointers, and hashing), clean, review-ready code, and the explanation skills that distinguish hires. In 2026 expect familiar medium-to-hard problems plus newer twists: AI-enabled or multi-file coding rounds at some companies, more emphasis on explainability and edge-case reasoning, and occasional real-world performance constraints (streaming, concurrency, memory limits). Interviewers evaluate problem framing, algorithm choice, complexity trade-offs, test-case thinking, and communication under time pressure. Best prep mixes pattern-based practice, timed mock interviews, code-review style polishing, and rehearsed explanations of complexity and tradeoffs. Focus your last-mile prep on writing correct, readable code quickly and on explaining why your solution is robust and efficient for production scenarios.

"I got asked a hardcore MCM DP question and I saw it on PracHub as well. Solved that question in 5 minutes. Without PracHub I doubt I could solve it in 5 hours. Though somehow didn't get hired, perhaps I guess I solved it too fast? /s"

"Believe me i'm a student here jn US. Recently interviewed for MSFT. They asked me exact question from PracHub. I saw it the night before and ignored it cause why waste time on random sites. I legit wanna go back and redo this whole thing if I had chance. Not saying will work for everyone but there is certainly some merit to that website. And i'm gonna use it in future prep from now on like lc tagged"

"10 years of experience but never worked at a top company. PracHub's senior-level questions helped me break into FAANG at 35. Age is just a number."

"I was skeptical about the 'real questions' claim, so I put it to the test. I searched for the exact question I got grilled on at my last Meta onsite... and it was right there. Word for word."

"Got a Google recruiter call on Monday, interview on Friday. Crammed PracHub for 4 days. Passed every round. This platform is a miracle worker."

"I've used LC, Glassdoor, and random Discords. Nothing comes close to the accuracy here. The questions are actually current — that's what got me. Felt like I had a cheat sheet during the interview."

"The solution quality is insane. It covers approach, edge cases, time complexity, follow-ups. Nothing else comes close."

"Legit the only resource you need. TC went from 180k -> 350k. Just memorize the top 50 for your target company and you're golden."

"PracHub Premium for one month cost me the price of two coffees a week. It landed me a $280K+ starting offer."

"Literally just signed a $600k offer. I only had 2 weeks to prep, so I focused entirely on the company-tagged lists here. If you're targeting L5+, don't overthink it."

"Coaches and bootcamp prep courses cost around $200-300 but PracHub Premium is actually less than a Netflix subscription. And it landed me a $178K offer."

"I honestly don't know how you guys gather so many real interview questions. It's almost scary. I walked into my Amazon loop and recognized 3 out of 4 problems from your database."

"Discovered PracHub 10 days before my interview. By day 5, I stopped being nervous. By interview day, I was actually excited to show what I knew."

"I recently cleared Uber interviews (strong hire in the design round) and all the questions were present in prachub."
"The search is what sold me. I typed in a really niche DP problem I got asked last year and it actually came up, full breakdown and everything. These guys are clearly updating it constantly."
Select words to maximize unique characters
Problem You are given an array of strings words. You may choose any subset of these strings and concatenate the chosen strings in any order. Your goal...
Find shortest path on infinite grid
You are given an infinite 2D grid with integer coordinates. From a cell (x, y) you may move in 4 directions (North/South/East/West) by 1 cell per move...
Find Top K Largest Numbers
Given an unsorted array of integers nums and an integer k, return the k largest numbers in the array. The solution should use a heap rather than sorti...
Build a Wordle-style game in React
Task Implement a simplified Wordle-style game as a small React app. No styling/CSS is required (plain HTML output is fine). Game rules (assume Wordle-...
Minimize shortest path by adding weight-1 edges
You are given a weighted directed graph with nodes labeled 1..n. The existing edges are described by three arrays of equal length m: - from[i]: start ...
Determine Exact Layover Booking
You are given a layover duration target_hours and a list of experience durations durations, such as [2.0, 3.6], where each number represents the numbe...
Implement a Hierarchical File System
Implement an in-memory hierarchical file system. Create a class FileSystem with the following methods: - FileSystem() initializes an empty file system...
Support Dynamic Range Sums
Implement a data structure over an integer array nums. Part 1: If the array never changes, support sumRange(left, right) that returns the sum of eleme...
Find longest increasing contiguous subarray
Problem You are given an integer array nums (length n). Part 1 Find the length of the longest contiguous subarray that is strictly increasing (i.e., f...
Debug Queues and Solve Arrays
During the coding rounds, the interviewer asked several implementation problems: 1. Debug a priority queue. You are given an array-backed min-heap. Th...
Decide target via subsequence plus/multiply expression
Question Given a sequence of positive 32-bit integers A and an integer target, determine whether there exists a subsequence of A (preserving order, us...
Implement dasher active-time calculator
Implement a function that, given a dasherId, a local pay-period interval [startLocalDateTime, endLocalDateTime), and a list of order events of the for...
Compute height after deletions; enumerate valid delete sets
Warm-up: You are given a rooted binary tree with unique node ids and a list of ids to delete. When a node is deleted, promote all of its children to b...
Evaluate query ratios from equations
You are given equations of the form A / B = value where A and B are variable names (strings) and value is a positive real number. You also receive que...
Find target-heavy sliding windows
Given an integer array nums, an integer target, and a fixed window size k, solve the following two tasks: 1. Return all contiguous subarrays of length...
Implement store, evaluator, and parser
The interview included several independent coding problems: 1. Implement an in-memory key-value store. Start with basic put/get operations, then exten...
Implement an asyncio-based chat server
Async Chat Server (Python asyncio) Build a TCP chat server using Python's asyncio. The server listens on a given port and serves many concurrent clien...
Reverse Words While Preserving Spaces
Implement a C++ function that reverses the order of words in a string. Assume a word is any maximal sequence of non-space characters, and the input co...
Apply Range Overwrite Queries
You are given an integer array nums of length n and a list of range-assignment queries. Each query is a tuple (left, right, value), where left and rig...
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] =...