Which of the following is a characteristic of a greedy algorithm ?
2025
Which of the following is a characteristic of a greedy algorithm ?
- A.
It makes decisions based on global information
- B.
It always produces the optimal solution
- C.
It makes decisions based on local information
- D.
It uses backtracking to explore multiple solutions
Attempted by 102 students.
Show answer & explanation
Correct answer: C
A greedy algorithm makes locally optimal choices at each step without considering the global picture. This approach builds up a solution incrementally, hoping that local choices lead to a globally optimal result.