• Image placeholder
  • 홈 페이지
  • 블로그 센터
  • 범주
Image placeholder

twopointer

물이 가장 많은 용기

길이가 n인 정수 배열 높이가 주어집니다. i번째 선의 두 끝점이 (i, 0)과 (i, height[i])가 되도록 n개의 수직선이 그려집니다. 컨테이너에 가장 많은 물이 들어 있는 것과 같이 x축과 함께 컨테이너를 형성하는 두 개의 선을 찾습니다. 용기가 저장할 수 있는 최대 물의 양을 반환합니다. 컨테이너를 기울일 수 없습니다. https://leetcode.com/problems/con...

arrayleetcodetwopointer

© 2022 intrepidgeeks.com

Privacy Policy Contact US Sitemap
🍪 This website uses cookies to ensure you get the best experience on our website. Learn more