Given an array of heights, find two lines that together with the x-axis form a container that holds the most water. Example: height = [, , , , , , , , ] Output: . Lines at indices and (heights and ) form a container with width and height , giving area . The area is min(height[i], height[j]) × (j - i).
##### ###### ##### ### # # ### # # ###### ## ## ## ## ## ## ## # # # # # ## ##### #### ##### # # # # # # # #### ## # ## ## ## ## # # # # # ## ## # ###### ## ### # ### # ######
$ curl repovive.com/roadmaps/maang-interview-prep/two-pointers-sliding-window/problem-container-with-most-water
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░███████████████████████████████████████████████████████████████████████████████████████████████████████████████