CSC325 · 2081 · 10 marks
Does greedy algorithm guarantee optimal solution? Solve the Fractional knapsack problem to find maximum loot from given information. | Item | 1 | 2 | 3 | 4 | 5 | 6 | 7 | |---|---|---|---|---|---|---|---| | Value | 12 | 10 | 20 | 15 | 2 | 3 | 50 | | Weight (kgs) | 2 | 1 | 3 | 2 | 12 | 10 | 1 |
Does greedy algorithm guarantee optimal solution? Solve the Fractional knapsack problem to find maximum loot from given information.
| Item | 1 | 2 | 3 | 4 | 5 | 6 | 7 |
|---|---|---|---|---|---|---|---|
| Value | 12 | 10 | 20 | 15 | 2 | 3 | 50 |
| Weight (kgs) | 2 | 1 | 3 | 2 | 12 | 10 | 1 |
[10]
Design and Analysis of AlgorithmsChapter 4: Greedy AlgorithmsGreedy AlgorithmsNumerical: Fractional knapsack