Min Operations to Sort All Packages
Asked at Amazon · Coding & Leetcode-style Questions · Difficulty: Medium
In an Amazon distribution center, a large number of parcels arrive daily, each assigned a distinct identifier ranging from 1 to n. The warehouse supervisor is tasked with organizing these parcels, but not by their identifiers. Instead, they need to follow a specific order provided by the sortingSequence, which is a permutation of the integers from 1 to n, ensuring the most efficient handling.
Loading the problem…