Your Dashboard
Interview Coaching
Learn
System Design
ML System Design
Code
Behavioral
Salary Negotiation
Interview Guides
Leetcode 3205. Maximum Array Hopping Score I
Given an integer array, compute the maximum score obtainable by starting at index 0 and repeatedly hopping forward under a constraint (e.g., a maximum jump distance), where your score is the sum of visited elements; this reduces to DP with dp[i] = arr[i] + max(dp[j]) over reachable j and is typically solved with a sliding-window maximum structure (monotonic deque or max-heap) for efficiency.
Asked at:
Question Timeline
See when this question was last asked and where, including any notes left by other candidates.
Early January, 2025
Junior
Given an array of positive elements, find the max score by choosing to take or skip elements. If taken, score increases by arr[i] and next position is i + arr[i].
Comments
Hello Interview Premium
Your account is free and you can post anonymously if you choose.