Leetcode 3413. Maximum Coins From K Consecutive Bags
Given non-overlapping segments where every integer position in [li, ri] holds ci coins, find the maximum total coins covered by any contiguous window of k integer positions. Coordinates and k are up to 1e9, so the challenge is to slide/sweep a length-k window efficiently over sparse weighted intervals without expanding individual positions.
Asked at:
Amazon
Question Timeline
See when this question was last asked and where, including any notes left by other candidates.
0
Early August, 2026
Mid-level
Early August, 2026
Mid-level
Early July, 2026
Mid-level
Hello Interview Premium
Your account is free and you can post anonymously if you choose.