Company: Myntra_20sep
Difficulty: medium
Maximum Sum of Three Non-Overlapping Subarrays Problem Description You are working on an analytics application that helps businesses monitor performance over time. In this case, the application analyzes the sales data of different products over several months. The sales data is provided in the form of an integer array nums , where each element represents the sales of a product for a specific month. Your task is to find three non-overlapping subarrays of length k that have the maximum total sum, and return their starting indices. Since businesses want to optimize sales strategies, they are interested in identifying the time periods (subarrays) with the highest sales. To solve this problem efficiently, you must consider the following: Three subarrays: The subarrays must not overlap. Each subarray should be exactly of length k . Maximum sum: The total sum of the three subarrays should be maximized. Lexicographical order: If multiple solutions with the same sum exist, return the one with t