
单调栈
永远的EMT
每天时刻保持超越自我的意识
展开
-
【LeetCode】Largest Rectangle in Histogram
Givennnon-negative integers representing the histogram's bar height where the width of each bar is 1, find the area of largest rectangle in the histogram. Above is a histogram where width of ea...原创 2019-07-01 01:31:04 · 306 阅读 · 1 评论 -
【LeetCode】42. Trapping Rain Water
Givennnon-negative integers representing an elevation map where the width of each bar is 1, compute how much water it is able to trap after raining. The above elevation map is represented by array...原创 2019-07-01 01:41:29 · 227 阅读 · 0 评论 -
【LeetCode】901. Online Stock Span
Write a classStockSpannerwhich collects daily price quotes for some stock, and returns thespanof that stock's price for the current day. The span of the stock's price todayis defined as the maxi...原创 2019-07-01 01:55:54 · 245 阅读 · 0 评论 -
【LeetCode】739. Daily Temperatures
Given a list of daily temperaturesT, return a list such that, for each day in the input, tells you how many days you would have to wait until a warmer temperature. If there is no future day for which...原创 2019-07-01 02:00:17 · 187 阅读 · 0 评论