1.

The Knapsack problem is an example of ____________(a) Greedy algorithm(b) 2D dynamic programming(c) 1D dynamic programming(d) Divide and conquerThis question was addressed to me in class test.Question is taken from 0/1 Knapsack Problem in chapter Dynamic Programming of Data Structures & Algorithms II

Answer» CORRECT option is (B) 2D dynamic programming

The explanation is: KNAPSACK problem is an example of 2D dynamic programming.


Discussion

No Comment Found

Related InterviewSolutions