Sell Diminishing-Valued Colored Balls at MathWorks
Medium30.1% acceptance
This problem has 100.0% frequency at MathWorks.
Problem Description
You have an `inventory` of different colored balls, and there is a customer that wants `orders` balls of **any** color. The customer weirdly values the colored balls. Each colored ball's value is the number of balls **of that color **you currently have in your `inventory`. For example, if you own...
Read full problem and hintsTopics
Also asked at 4 companies
More MathWorks Questions
Maximum Number of AlloysMediumReshape the MatrixEasyMaximum Palindromes After OperationsMediumTotal Cost to Hire K WorkersMediumCount AnagramsHard
View all MathWorks questions