Container With Most Water
Given an integer array heights of length n, where heights[i] is the height of the vertical line at index i, choose two lines i and j (i < j) to form a container with the x-axis.
The amo...
Example
Unlock to view complete problem details
and practice with sample input/output
Was this article helpful?
View Test Cases & Run Code requires membership
Standard Input
Execution Result:
