Usage examples of greedy algorithms?

后端 未结 10 1839
孤城傲影
孤城傲影 2021-02-02 15:36

What is the use of greedy algorithms? An real example?

相关标签:
10条回答
  • 2021-02-02 16:25

    A real life example of Greedy Algorithm will be Interval Scheduling.

    For example if you want to maximize the number of customers that can use a meeting room, you can use Interval Scheduling Algorithm.

    0 讨论(0)
  • 2021-02-02 16:28

    Application of greedy method

    Prim’s Algorithm , Kruskal Algorithm

    0 讨论(0)
  • 2021-02-02 16:30

    Some problems are such that a greedy solution will actually be optimal, and sometimes they're engineered that way. A fun example is that many countries' coin values are such that a greedy approach to returning change (i.e. always returning the largest-possible coin until you're done) works.

    0 讨论(0)
  • 2021-02-02 16:34

    http://en.wikipedia.org/wiki/Greedy_algorithm

    0 讨论(0)
提交回复
热议问题