64.2k views
0 votes
Which of the following is not true about greedy algorithms?

A.It makes the locally optimal choice at each stage
B.A greedy strategy produces an optimal solution
C. A greedy algorith exists for constructing the minimum spanning tree
D.A greedy algorithm exists for partition a set of n weights into k buns where each has the same weight
E. Greedy algorithm exists for some NP-hard problems.

User Mcnicholls
by
9.0k points

1 Answer

2 votes

Answer:D)A greedy algorithm exists for partition a set of n weights into k buns where each has the same weight

Explanation: A greedy algorithm is the algorithm that helps in the optimization during any issue in the operating system field.It helps in making the best utilization of the situation and thus makes the optimal choice.

By functioning at each step/stage in optimal way,the problem/issue gets solved with the minimal spanning tree form.Non-deterministic polynomial-time(NP) hardness issues can be find a optimal solution through this method.Therefore all the statement are correct except option(d).

User Jonsb
by
8.5k points