Grid BFS & Flood Fill
Graph problems at Intuit usually come as grids. The intern Glider OA has used a spreading-virus grid more than once, where the virus spreads to its four neighbors each second. An SDE-2 phone screen asked something close to it, with produce in place of cells. Sizing the biggest connected region has come up in a video round and in an intern first round that went on to flipping one cell. Finding which cells can reach both borders of a map came up in an Assessor round for an experienced backend hire, run on Glider against hidden tests.
Counting regions on a grid is covered in Trees & Graphs, and these three problems build on the same traversal. The virus problem starts from many cells at once and measures time. For the region problem you return how big each region is instead of how many there are. On the two-border problem you turn the question around and flood inward from the edges of the map. Neighbors and visited marks stay the same in all three, and what changes is how you read the result.
IntuitPremium lesson · Coding round
The 3 Intuit problems are below.
- A Premium questionCoding · Medium · Frequently asked
- A Premium questionCoding · Medium
- A Premium questionCoding · Medium
Each with hints, the follow-up and a tested solution.
Get the Intuit questions$49 a year · all 100 companies · cancel anytime
From 309 Intuit reports, forum threads behind logins and write-ups in Chinese.
Intuit interview guideKnow what Intuit asks before you walk in.
28 coding · 5 system design · 21 behavioral questions
Get their questions first.
InterviewLegend is independent and not affiliated with or endorsed by any company it covers.