Stuff Baskets everyone.
Source: Iran National Olympiad - 2014 Second Round - D1P1
May 1, 2014
combinatorics unsolvedcombinatorics
Problem Statement
A basket is called "Stuff Basket" if it includes kilograms of rice and number of eggs. A market is to distribute Stuff Baskets. We know that there is totally kilograms of rice and number of eggs in the baskets, but some of market's baskets include either more or less amount of rice or eggs. In each step, market workers can select two baskets and move an arbitrary amount of rice or eggs between selected baskets. Starting from an arbitrary situation, what's the minimum number of steps that workers provide Stuff Baskets?