HDU 2795 Billboard

这题是用线段树作,把H当作叶子节点,设置左儿子最大值,和右儿子最大值两个数组,若是左儿子大就往左儿子查找,右儿子大就往右儿子查找。 #include <stdio.h> #include <string.h> #include <iostream> #include <algorithm> #define maxn 200000 #define mem(a) memset(a, 0, sizeof
相关文章
相关标签/搜索