Search
⌘K
Get Premium
Leetcode 135. Candy
Given a line of children with integer ratings, assign each at least one candy so any child with a higher rating than a neighbor gets more candies, and compute the minimum total required; the core challenge is balancing local increases/decreases across the array (typically handled by scanning increasing/decreasing runs or a two-pass greedy) in linear time.
Asked at:
M
Marvin
Paypal
Question Timeline
See when this question was last asked and where, including any notes left by other candidates.
All Regions
Early December, 2025
M
Marvin
Mid-level
Late October, 2025
Paypal
Staff
Comments
Hello Interview Premium
Your account is free and you can post anonymously if you choose.