Introduction
It is the medium level algorithm in the weekly contest 104. I wrote the solution using two iterations of the array, one is to keep maximum of prefix and minimum of suffix.
My practice
Here is my discuss link. I also learned to write one pass, and then I wrote the reply in one of posts here.
No comments:
Post a Comment