Company: Uber_23july
Difficulty: medium
Package Drop Optimization Problem Description The Uber Connect package delivery team is reviewing how delivery agents handle packages across multiple zones. For each of the n delivery zones: scheduledDrop[i] stores the scheduled time (in minutes) to drop the package in the i-th zone. realDrop[i] stores the actual time (in minutes) the package was dropped in the i-th zone. Due to system limitations, the assignment of scheduled times and actual times to zones was not fixed, and the two arrays can be shuffled independently of each other before analysis. To evaluate overall performance, Uber calculates a weighted drop delay, where each zone is given a weight equal to its zone number. Using 1-based indexing, the weighted drop delay is defined as: Total Weighted Drop Delay = sum over i = 1..n of i * (realDrop[i] - scheduledDrop[i]) You may reorder scheduledDrop in any way and, separately, reorder realDrop in any way. Implement the function maximizeDropDelay that returns the maximum possible