Squirrel Simulation
A medium-tier problem at 57% community acceptance, tagged with Array, Math. Reported in interviews at Block and 0 others.
Squirrel Simulation is a medium-difficulty problem that Block has asked candidates. With a 57% acceptance rate, it's not a gimme, but it's also not a wall. The problem tests whether you can translate a physical simulation into code: you've got a squirrel, acorns scattered on a grid, and constraints on how far the squirrel can travel. The trick isn't the algorithm itself. It's catching the edge cases in movement logic and not overthinking the path. If this lands in your live assessment and you stall on coordinate math, StealthCoder solves it invisibly in seconds.
Companies that ask "Squirrel Simulation"
Squirrel Simulation 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. Built by a senior engineer who knows the OA is theater. This is the script.
Get StealthCoderThe core pattern is Array and Math: iterate through acorn positions, calculate distances, and determine reachability within a movement budget. Most candidates fail because they confuse Manhattan distance with Euclidean, or they implement movement constraints incorrectly. The obvious approach is greedy: always grab the closest acorn. That often works, but the trap is assuming any order of collection is optimal when tree placement or movement rules impose hard constraints. You need to track state cleanly: current position, remaining energy or moves, collected acorns. The problem punishes sloppy coordinate bookkeeping. Since it's only asked at one major company in reports, it's not on the interview circuit rotation, which means less public write-up and more surprise factor. If you haven't drilled it and hit it live, StealthCoder is the hedge that delivers a working solution while you stay calm.
Pattern tags
You know the problem.
Make sure you actually pass it.
Squirrel Simulation 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. Built by a senior engineer who knows the OA is theater. This is the script. Works on HackerRank, CodeSignal, CoderPad, and Karat.
Squirrel Simulation interview FAQ
Is this really a medium, or does it feel harder?+
57% acceptance rate means slightly more than half pass it. It's medium on effort, not ambiguity. The frustration comes from state management and distance calculation, not algorithmic insight. Once you map movement and collection correctly, the solution is straightforward.
What's the trick to avoiding TLE or WA?+
Don't recalculate distances repeatedly. Pre-compute or cache them. Track your current position and collected state carefully. The most common WA is forgetting to validate that movement is actually possible given the constraints, not just that distance is within budget.
Should I use BFS or greedy?+
Greedy often works, but verify the constraints first. If the problem allows any order of collection and only measures total distance, greedy by nearest acorn is fast. If there's a specific tree order or energy decay per move, BFS or DP might be required. Read the problem carefully.
How does this relate to other Array and Math problems?+
It combines distance computation (Math) with iteration and state tracking (Array). It's lighter on dynamic programming than other medium grid problems. Think of it as a shorter cousin to shortest path or knapsack, not a harder variant.
Is Block still asking this, or is it old data?+
Block is in the record as having asked it. We don't have frequency or recency data, so treat it as plausible for that company. Low company count means it's not a hot problem across the industry, which makes it a wildcard in your prep.
Want the actual problem statement? View "Squirrel Simulation" on LeetCode →