Given number of items and maximum capacity…each item has corresponding id, profit and weight. How to find the subset in order to make the maximum possible profit using dp???
Please help me…to solve this question.
Input :
3 11
1 5 4
2 12 10
3 8 5
Output:
{1,3}
Explain : here 1st and 3rd items can be selected.
Peroblem link
I know that in bottom up ,0-1 knapsack calculation table the first row and column will be zero …but your code it could not exists…Is it optional or mandatory???