Company: Amazon_24sep
Difficulty: medium
Maximum Storage Efficiency Problem Description You're managing Amazon's cloud storage system. There are n tasks that need to be processed, and the j th task is broken into num_segments[j] segments. The cloud storage is divided into m storage units. The segments are allocated to these units with the following rules: Each segment is stored in exactly one storage unit. Each storage unit must hold at least one segment. A storage unit cannot contain segments from more than one task. The storage efficiency is measured by the minimum number of segments that any storage unit contains. Your task is to organize the segments in such a way that this storage efficiency is maximized. Function Description Complete the function getMaximumStorageEfficiency in the editor below with the following parameter(s): int num_segments[n] : the number of segments a process is divided into long m : the number of storage units Returns: int : the maximum storage efficiency Examples Example 1: n = 3 num_segments = {7