给定n个非负整数a1,a2。。。,an,其中每个表示坐标(i,ai)处的点。绘制n条垂直线,使得线i的两个端点位于(i,ai)和(i,0)。找到两条线,这两条线与x轴一起形成一个容器,使容器包含最多的水。
Given n non-negative integers a1, a2, ..., an , where each represents a point at coordinate (i, ai). n vertical lines are drawn such that the two endpoints of the line i is at (i, ai) and (i, 0). Find two lines, which, together with the x-axis forms a container, such that the container contains the most water. (2021-12-16, JavaScript, 0KB, 下载0次)
采用js语言实现数据结构相关逻辑,具体链接(<http: www.liuyiqi.cn tags %E6%95%B0%E6%8D%AE%E7%BB%93%E6%9E%84%E4%B8%8E%E7%AE%97%E6%B3%95 page 2 >
采用js语言实现数据结构相关逻辑,具体链接(<http: www.liuyiqi.cn tags %E6%95%B0%E6%8D%AE%E7%BB%93%E6%9E%84%E4%B8%8E%E7%AE%97%E6%B3%95 page 2 > (2019-04-02, JavaScript, 4KB, 下载0次)