11. Container With Most Water
Container With Most Water - LeetCode 주어진 길이 n의 정수 배열 height가 있습니다. i번째 줄의 끝점은 (i, 0)와 (i, height[i])입니다. 가장 많은 물을 담을 수 있는 용기를 형성하는 두 개의 선을 찾아, 이 용기가 담을 수 있는 최대 물의 양을 반환합니다. You are given an integer array height of length n. There are n vertical lines drawn such that the two endpoints of the ith line are (i, 0) and (i, height[i]). Find two lines that together with the x-axis form a container, suc..
LeetCode
2023. 11. 2. 00:06