Teaching UGC NET Mock Test Series 2025 (Paper 1 & 2) Algorithms Algorithm Design Techniques Greedy Algorithms
Let us consider that the capacity of the knapsack W = 80 and the list of provided items are shown in the following table.
|
Items |
1 |
2 |
3 |
4 |
|
Profit(P) |
120 |
60 |
60 |
100 |
|
Weight(W) |
30 |
60 |
20 |
50 |
Find the maximum profit gain by applying fractional knapsack.
1
220
2
160
3
240
4
280