Your Dashboard
Interview Coaching
Learn
System Design
ML System Design
Code
Behavioral
Salary Negotiation
Interview Guides
Leetcode 2214. Minimum Health to Beat Game
Given a map of rooms/levels that alter your health (positive or negative), compute the minimum initial health required to reach the goal without your health ever dropping to zero; this is typically solved with dynamic programming (often working backward) to combine allowed moves and account for cumulative damage and healing.
Asked at:
Amazon
Question Timeline
See when this question was last asked and where, including any notes left by other candidates.
Late January, 2025
Amazon
Mid-level
Determine the minimum starting health for a player to win a game where they lose health each round and can use armor once
Mid January, 2025
Amazon
Mid-level
Minimum Starting Health to Win the Game: Given an array of power costs for n rounds and an armor value, determine the minimum starting health required to win the game. The player loses power[i] health each round, can use armor once to reduce damage, and must always have health > 0.
Comments
Hello Interview Premium
Your account is free and you can post anonymously if you choose.