Question: Now let's get the estimated value and weight for one warehouse.You need to write a function get_max_value which could do the following 4 things: Calculate

Now let's get the estimated value and weight for one warehouse.You need to write a function "get_max_value" which could do the following 4 things: Calculate the Value_Weight Ratio for each product. Sort the calculated Value_Weight Ratios in descending order. Select the products from the top of the descending order to the bottom while looking at the accumulated weight of products to make sure the accumulated weight does not exceed the warehouse weight capacity. Calculate the corresponding estimated value for this warehouse after finishing product selection. Remember, take every product into consideration; otherwise, you may have the risk of missing products. You want to put as many product with highest Value_Weight Ratio as possible before reaching the weight capacity for this warehouse

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related General Management Questions!