LeetCode 84: Which Bar Limits a Contiguous Rectangle?
Problem Requirement You are given a non-negative integer array heights. Each heights[i] is the height of a bar with width 1, and all bars are adjacent. Return the area of the largest rectangle that can be formed in the histogram. A legal rectangle covers a contiguous interval of bars. Its width is the number of bars in that interval, and its height cannot exceed the shortest bar in the interval. ...