Container With Most Water
Given n non-negative integers representing vertical lines at positions 1..n, choose two lines that together with the x-axis form a container holding the most water. Print the maximum area.
Constraints
2 <= n <= 10^5 0 <= height[i] <= 10^4
Discussion
No discussions yet.
Shalyam Support
Hi! Ask us anything — we'll reply on WhatsApp or Telegram within 24 hours.