Question DSA-DP-0029
Easy0/1 knapsack: capacity 5, items (weight, value) = (2, 3), (3, 4), (4, 5). What is the best total value?
- A.
5
- B.
9
- C.
Sign up free to see the answer and a step-by-step explanation.
Popular companies
Prepare company by company
Hiring pattern, syllabus, past questions and mocks for each company.
All companiesPractice by subject
Dynamic Programming question
0/1 knapsack: capacity 5, items (weight, value) = (2, 3), (3, 4), (4, 5). What is the best total value?
5
9
Sign up free to see the answer and a step-by-step explanation.
8
7