Analogy of Greedy Algorithms vs Dynamic programming
This paper discussed the intermediaries between two approaches to problem-solving Algorithm greed and dynamic programming. In this paper we have examined the greedy and dynamic algorithms for the 0/1 Knapsack Problem and the fractional Knapsack Problem. This is a combinatorial challenge for optimization in which the benefit of objects must be maximized while not exceeding capacity. Since it is an NP problem, it is not possible to achieve an exact solution for a large input. As a result, the paper provides a comparison of the Greedy and dynamic methods. It also provides the complexity of each algorithm in terms of time and space requirements. Our experimental results show that in greedy and dynamic programming approaches which is the most promising.
Keywords - Greedy Algorithm, Dynamic Programming, 0/1 Knapsack, Algorithm, fractional Knapsack, complexity.