Topics / Greedy Algorithms
⚡
Greedy Algorithms
When making the locally best choice produces the globally best answer.
Why learn Greedy Algorithms?
-
Often the simplest correct solution exists — if greedy works.
-
Teaches you to reach for proofs (exchange argument) before code.
-
Frequent in scheduling, intervals, and resource problems.
What you can build with Greedy Algorithms
Interval and scheduling problems Coin change and resource allocation Graph algorithms like Kruskal and Prim
Greedy Algorithms tutorials
2 articles · page 1 of 1Hand-written tutorials, ordered as a recommended learning path.
- 01 Greedy Algorithms Master greedy algorithm patterns for LeetCode including interval scheduling, activity selection, jump games, and proving greedy correctness.
- 02 Buy & Sell II Solve the multi-transaction stock problem with the greedy peak-valley insight: sum every positive daily delta. Includes complexity analysis and DP alternative.