Day 8 of 250: LeetCode 121 Best Time to Buy and Sell Stock | Greedy State Tracking Explained
You do not need to check every buy-sell pair. One pass, two variables, and the right greedy instinct is all it takes. Here is the full breakdown of LeetCode 121 with a deep dry run and interview tips.
Rahul Kumar