Dynamic Programming
Most OpenAI coding rounds are builds, but some candidates also get a live algorithm round, and dynamic programming comes up there. In one detailed account, a single grid problem was asked three ways in one session. The interviewer asked for the best score first, then for a path that earns it, then for the number of paths that tie. The build rounds add follow-ups the same way. The design you pick for the first ask decides whether the next two are small additions or a rewrite, so before you write the loop, say in one sentence what the state is. In the grid, it's the best score landing on a cell after u jumps. If the state is missing a dimension, you'll often notice while you're saying it.
The question about runs that avoid a Premium question comes from the HackerRank online assessment instead, where nobody is there to clarify the wording. Its prompt calls the runs "sub-sequences", but the sample shows it means consecutive integers, so check the samples before you trust the prompt.
OpenAIPremium lesson · Coding round
The 3 OpenAI problems are below.
- A Premium questionCoding · Medium
- A Premium questionCoding · Hard
- A Premium questionCoding · Medium
Each with hints, the follow-up and a tested solution.
Get the OpenAI questions$49 a year · all 100 companies · cancel anytime
From 20,000+ candidate reports, forum threads behind logins and write-ups in Chinese.
OpenAI interview guideKnow what OpenAI asks before you walk in.
31 coding · 6 system design · 19 behavioral questions
Get their questions first.
InterviewLegend is independent and not affiliated with or endorsed by any company it covers.