Available question text
Find three non-overlapping subarrays of length k whose total sum is maximized and return their starting indices (choose the lexicographically smallest tuple on ties). This is solved by computing k-length window sums and using prefix-sum/sliding-window + DP-like scans to track the best left and right intervals for each possible middle interval in linear time.
Related questions
Continue with questions that share topics or the same question type.
- Maximum Number of Non-Overlapping Subarrays With Sum Equals Target
Coding
- Maximum Sum of Two Non-Overlapping Subarrays
Coding · Array · Dynamic Programming · Sliding Window
- Find Two Non-overlapping Sub-arrays Each With Target Sum
Coding
- Maximum Number of Non-overlapping Palindrome Substrings
Coding
Sources · 1 reference
These records explain where the question appears. A company tag or candidate report does not guarantee a future interview question.
Hello Interview · 1 record
Meta
Leetcode 689. Maximum Sum of 3 Non-Overlapping Subarrays
Reported Jan 15, 2025 · 1 source report
SENIOR
Source snapshot: Nov 12, 2026
View source