Maximum Product Subarray
link
Key ideas
We want to have even or 0 negative numbers in the subarray, so that the product will be positive.
The challenge is we never know if we will eventually get even negative numbers, so we need to maintain 3 variables
local_max: the maxi...
brianhu.hashnode.dev2 min read