Coding & Algorithms Interview Questions
Practice 3,469 real coding and algorithms interview questions reported from interviews at Meta, Amazon, Google, Uber and Microsoft. The mix follows what these loops actually ask: arrays and strings, hash maps, two pointers and sliding windows, binary search, linked lists, trees and graphs, BFS and DFS, recursion and backtracking, dynamic programming, heaps and priority queues, and the occasional design-a-data-structure round. Roughly four in five are rated medium, which is where most technical screens sit; 477 are hard and cluster in onsite loops. 3,033 of them open in a console where you can run your solution against the test cases in Python, Java, C++ or JavaScript. 2,712 come from Software Engineer interviews, with the rest from Machine Learning Engineer, Data Scientist and Data Engineer loops, and 404 were set as take-home projects rather than live sessions.

"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."
Find a split-stay booking across listings
This question evaluates understanding of interval coverage and algorithmic problem solving, specifically reasoning about continuous date ranges, split...
Implement a traffic-light UI with JS
Frontend Coding: Traffic Light Build a simple traffic light component using HTML + CSS + JavaScript. Requirements - Render a vertical traffic light wi...
Increment Digit Array
This question evaluates a candidate's competency in array manipulation and elementary arithmetic on digit sequences, including carry propagation and h...
Return the k-th row of Pascal-like triangle
This question evaluates combinatorics, array manipulation, and space-efficient algorithm design by requiring computation of a specific row of Pascal’s...
Count Numbers With Odd Zeros
Given an array a of non-negative integers, count how many elements contain an odd number of digit '0' in their decimal representation. Notes: - Treat ...
Implement composition and mixin utilities
This question evaluates functional programming concepts (function composition and variable-argument handling) and object-oriented serialization patter...
Answer k-step ancestor queries in a rooted tree
This question evaluates proficiency with tree data structures and ancestor-query algorithms, focusing on reasoning about parent arrays, upward travers...
Design command executor with undo
This question evaluates understanding of the command pattern, state and history management, failure handling, and appropriate data structure use for i...
Count ordered fragment pairs forming a password
This question evaluates proficiency with string manipulation, handling duplicate fragments, and combinatorial reasoning about ordered index pairs that...
Find robots matching obstacle-distance signature
This question evaluates spatial reasoning on 2D grids, the ability to compute distance signatures to nearest obstacles, and careful handling of bounda...
Linear Interpolator with Extrapolation
Linear Interpolator with Extrapolation You are given n knot points in a 2D coordinate system, where knots[i] = [x_i, y_i]. All x-coordinates are disti...
Design a 25,000-CSV ETL pipeline
This question evaluates data engineering and ETL pipeline design skills, specifically competencies in automation, schema validation, type standardizat...
Maximize score in 15-sum card game
This question evaluates algorithmic problem-solving in combinatorial search, state-space optimization, and memoization by asking for the maximum achie...
Write SQL for session analytics
This question evaluates SQL proficiency and data engineering competencies, including deduplication, joins, time-series aggregation, rolling-window cal...
Determine earliest collision among moving cars
You are given n cars moving over time. Each car has known initial state at time \(t=0\): - 1D case (straight road): - initial position \(x_i\) (mete...
Implement nested template string substitution
This question evaluates understanding of string processing, dependency resolution, recursive expansion, cycle detection, and efficiency techniques suc...
Maximize watched duration under consecutive-sum limit
You have a list of videos in a feed. Video i has duration d[i] (positive integer). A user has an “attention span” limit A. You want to select a subset...
Implement palindrome check and valid parentheses
You have 20–25 minutes per problem. Implement the following two functions and be prepared to explain your approach and time/space complexity. Problem ...
Debug and Fix Failing Unit Tests in Java
You receive a small Java project for a credit-card rewards service with three failing unit tests: calculatesTriplePointsForRestaurants, returnsUnknown...
Solve and optimize menu combo DP
Given up to N different menu items, each with a unit price, and a list of combo offers where each offer specifies quantities for some items and a tota...