Candy Crush
A medium-tier problem at 77% community acceptance, tagged with Array, Two Pointers, Matrix. Reported in interviews at Braze and 5 others.
Candy Crush is a medium-difficulty array simulation problem that appears regularly in assessments at Braze, Capital One, Rubrik, Visa, Roblox, and Pinterest. The 77% acceptance rate masks a common trap: the naive single-pass approach fails because gravity and cascades interact in ways that demand careful ordering. If you hit this problem live and freeze on the simulation logic, StealthCoder surfaces a working solution invisibly. The trick isn't exotic algorithm knowledge. It's understanding when and how to iterate.
Companies that ask "Candy Crush"
Candy Crush is the kind of problem that decides whether you pass. StealthCoder reads the problem on screen and surfaces a working solution in under 2 seconds. Invisible to screen share. The proctor sees nothing. Made for the engineer who has done the work but might still blank with a webcam pointed at him.
Get StealthCoderThe problem asks you to simulate candy falling and matching in a grid. Most candidates start by checking matches, removing them, dropping candies, then repeating. This fails because the order matters. You need to process gravity and chain reactions correctly. The pattern: drop candies column by column, then scan for matches row by row and column by column, remove them, and loop until no more matches exist. Array and two-pointer logic help you identify contiguous matches efficiently. Matrix iteration discipline prevents bugs. If your OA includes this and the obvious approach times out or fails test cases, StealthCoder's step-by-step simulation runs invisibly during screen share and gives you a working implementation instantly.
Pattern tags
You know the problem.
Make sure you actually pass it.
Candy Crush recycles across companies for a reason. It's medium-tier, and most candidates blank under the timer. StealthCoder is the hedge: an AI overlay invisible during screen share. It reads the problem and surfaces a working solution in under 2 seconds. Made for the engineer who has done the work but might still blank with a webcam pointed at him. Works on HackerRank, CodeSignal, CoderPad, and Karat.
Candy Crush interview FAQ
Is Candy Crush really a medium problem?+
The 77% acceptance rate suggests it's easier than typical mediums, but that's misleading. Most who pass have seen similar grid-simulation problems before. The real difficulty is getting simulation order right. One wrong loop sequence tanks your solution.
Why does my single-pass approach fail?+
Because candies fall after matches are cleared, which can create new matches. You must loop until the grid stabilizes. Each iteration: drop candies, find all matches, remove them, repeat. Skipping the loop structure is the most common mistake.
How do I avoid off-by-one errors in matching?+
Use two pointers or a simple counter to identify runs of three or more identical candies. Mark matches in a separate boolean grid first, then clear them. Separate marking from removal prevents index corruption during iteration.
Do I need to optimize for large grids?+
The problem likely uses modest grid sizes (under 10x10). A straightforward simulation with multiple passes is acceptable. Premature optimization often introduces bugs. Correctness first, then optimize if TLE appears.
Which companies ask this most often?+
It's been reported at Braze, Capital One, Rubrik, Visa, Roblox, and Pinterest. The spread suggests it's in rotation at mid-size and larger tech firms. If your target company is on this list, grid simulation is worth drilling.
Want the actual problem statement? View "Candy Crush" on LeetCode →