J
J
Jonh Doe2012-12-19 23:00:27
Algorithms
Jonh Doe, 2012-12-19 23:00:27

Calculation of the number of banknotes for the list of recipients

I would like a hint or a ready-made solution (algorithm, or ready-made in scripting language like php or something similar), on the next question.

There are stacks of banknotes (we know how many banknotes of each denomination)
There is a list of people with amounts
It is necessary: ​​to display how many banknotes each person needs to issue and what denomination, so that everything is approximately the same for everyone. Those. so that the latter does not have the entire amount in 10-ruble bills.

Thanks in advance for your replies and advice.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question