随笔分类 - 单调队列or栈
摘要:分别维护一个单调递减的队列和单调递增队列就可以了,但是这题莫名的坑,要用C++提交卡编译器的时间才能AC,真的是日了狗了,以后就用C++提交好了,不用别的了。 1 #include <iostream> 2 #include <queue> 3 #include <stack> 4 #include
阅读全文
摘要:D - Laying Cables Time Limit:2000MS Memory Limit:262144KB 64bit IO Format:%I64d & %I64u One-dimensional country has n cities, the i-th of which is loc
阅读全文

浙公网安备 33010602011771号