Feb-10-2021, 04:45 AM
Dear all, I am lerning Python and would like to know if it is possible to implement the following:
Lets suppose I'm a fruit distribuitor and I have in my stock: 3 bananas, 3 apples, 3 oranges.
And I have 3 markets with the current stock:
Market A: 1 orange / 2 apples / 3 banana
Market B: 2 oranges / 5 apples / 1 banana
Market C: 5 oranges / 1 apple / 2 banana
How would I program that python retrieve me the best market to fit each fruit and the ideal volume of it... based on the current stock and my distribuitor volume?
The answer for this would be:
Market A: receive: 2 oranges / 1 apple / 0 banana
Market B: receive: 1 oranges / 0 apple / 2 banana
Market C: receive: 0 oranges / 2 apple / 1 banana
However lts suppose that I have thousands of markets and many other thousands of fruits... Is this really possible?
Appreciate all support!!!
Greetings!

Lets suppose I'm a fruit distribuitor and I have in my stock: 3 bananas, 3 apples, 3 oranges.
And I have 3 markets with the current stock:
Market A: 1 orange / 2 apples / 3 banana
Market B: 2 oranges / 5 apples / 1 banana
Market C: 5 oranges / 1 apple / 2 banana
How would I program that python retrieve me the best market to fit each fruit and the ideal volume of it... based on the current stock and my distribuitor volume?
The answer for this would be:
Market A: receive: 2 oranges / 1 apple / 0 banana
Market B: receive: 1 oranges / 0 apple / 2 banana
Market C: receive: 0 oranges / 2 apple / 1 banana
However lts suppose that I have thousands of markets and many other thousands of fruits... Is this really possible?
Appreciate all support!!!
Greetings!

