"So to flood that seemed like a completely daft idea."
习题链接:LeetCode 496. 下一个更大元素 I
,更多细节参见搜狗输入法下载
The team is now planning to build a bigger space factory - one that could make semiconductor material for 10,000 chips.
思路:倒序遍历 + 单调索引栈(仅存索引),计算下一个高温的间隔天数。栈顶索引 - 当前索引即为等待天数。