Search
⌘K

Leetcode 3626. Find Stores with Inventory Imbalance

For each store with at least three distinct products, determine the most expensive and cheapest products and find stores where the most expensive product's quantity is less than the cheapest product's quantity. Report those stores with the product names, quantities and the imbalance ratio (cheapest_quantity / most_expensive_quantity) rounded to 2 decimals, ordered by ratio descending then store name ascending.


Question Timeline

See when this question was last asked and where, including any notes left by other candidates.

Comments

Your account is free and you can post anonymously if you choose.