Fewest Moves Across a Grid with a Wall-Breaking Budget
Asked at Apple · Coding Questions · Difficulty: Hard
A robot must cross a rectangular grid from the top-left cell to the bottom-right cell. Some cells are walls. The robot carries a limited number of charges, and each charge lets it break through one wall. Find the fewest moves the robot needs, or report that the trip is impossible.
Loading the problem…
More Apple interview questions
- LLM conceptual questions
- Implement a Two-Hidden-Layer MLP with Backpropagation in NumPy
- Compare PPO, DPO, and GRPO
- Implement a Vision Transformer (ViT) from Scratch
- Sample from a Gaussian Distribution Using Only Uniform Sampling
- ML Fundamentals and Model Debugging Rapid-Fire