OpenAI Software Engineer Coding & Algorithms Interview Questions
Practice 66 real Coding & Algorithms interview questions for Software Engineer roles at OpenAI.

"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."
Aggregate Recent Message Events And Active Chats
Prepare for a stateful event aggregation coding prompt over chat events and active chats in a rolling five-minute window. The question is useful for d...
Count Connected Friend Groups
Count Connected Friend Groups You are given an n x n symmetric adjacency matrix. is_connected[i][j] == 1 means person i and person j are directly conn...
Implement A Contiguous Memory Allocator With Free-Block Coalescing
Review a contiguous memory allocator coding prompt with malloc, free, first-fit allocation, block coalescing, and a best-fit follow-up. The interview ...
Add Consecutive-Value Bonuses to Grid Paths
Extend the maximum-score grid path with bonuses for equal adjacent values and strictly increasing triples of visited cells. Dynamic programming must r...
Find and Count Maximum-Score Grid Paths
Find the maximum-scoring path from a fixed top-row cell to the last row of a grid using diagonal, downward, and limited two-row jump moves. Return the...
Consistent Hashing Ring with Virtual Nodes for Shard Rebalancing
Consistent Hashing Ring with Virtual Nodes for Shard Rebalancing A distributed key-value store spreads its keys across a set of shards. When a shard i...
Infection Spread Simulation with Death Threshold
This question evaluates a candidate's ability to implement grid-based simulation with multi-state cellular automaton logic, testing practical applicat...
Spreading Contagion on a Grid
This question tests graph traversal and multi-source BFS on a 2D grid, evaluating a candidate's ability to model simultaneous state propagation across...
Implement a Distributed Rate Limiter
This question evaluates a candidate's ability to design and implement a distributed rate-limiting mechanism, testing knowledge of distributed systems,...
Implement IP Address Arithmetic
This question evaluates proficiency in IP addressing, parsing and validation, binary/address-space arithmetic, CIDR subnet calculation, and formatting...
Minimize deaths in spreading plant infection
This question evaluates a candidate's ability to model and simulate dynamic grid processes, reason about infection propagation and delayed state chang...
Implement Disease and Friend Snapshot Models
You are asked to solve two independent coding problems. Problem 1: Simulate disease spread on a contact graph There are n people labeled 0 through n -...
Compute Infection Time in a Grid
This question evaluates competence in grid-based graph traversal and simulation of propagation dynamics, focusing on state management, time-step model...
Implement Social Follow Recommendations
This question evaluates graph data structure design and traversal, set-based aggregation and ranking logic, and the ability to justify data structure ...
Generate Data Labeling Schedules
A data labeling platform manages tasks, AI models, and human annotators. Each entity has a 1-indexed string ID. You are given four integers: totalTask...
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...
Implement Persistent KV Store Serialization
Implement a persistent in-memory key-value store. Requirements: - Keys and values are arbitrary byte strings or UTF-8 strings; do not rely on delimite...
Implement Three Research Coding Tasks
This multi-part question evaluates skills in differentiable linear algebra and automatic differentiation safety, memory- and buffer-aware numerical im...
Implement a memory allocator with malloc/free
Problem You are implementing a simplified memory allocator over a contiguous memory region. Initialize the allocator with a fixed total size: - alloca...
Implement IPv4 iterators and CIDR expansion
Problem: IPv4 Iterators and CIDR Expansion You are implementing utilities to iterate over IPv4 addresses. An IPv4 address is in dotted-decimal form: A...