Find the maximum water a pair of vertical lines can hold using the two-pointer technique.
Constraints
Example
>>> max_area([1, 8, 6, 2, 5, 4, 8, 3, 7]) 49 >>> max_area([1, 1]) 1 >>> max_area([2, 3, 4, 5, 18, 17, 6]) 17
Recent Submissions
No submissions yet — hit Run Tests to try!
Hints