How does the order-statistic tree look like in Largest Rectangle in a Histogram problem
In http://blog.csdn.net/arbuckle/archive/2006/05/06/710988.aspx, it was me开发者_如何学Cntioned several methods to solve the Largest Rectangle in a Histogram problem. But I do not see how the first method, order-statistic tree, can be used to solve this problem. Could anyone please give a concrete example of this method, i.e. how the tree looks like for an example, let’s say, [7, 2, 1, 4, 5, 1, 3, 3]?
精彩评论