- 博客(2)
- 收藏
- 关注
原创 codeforces Educational Codeforces Round 53部分题解
交题的时候断网是真的坑… A题: A. Diverse Substring A substring of string s is a continuous segment of letters from s. For example, “defor” is a substring of “codeforces” and “fors” is not. The length of the substr...
2018-10-26 15:51:18 418
原创 51nod1275 连续子段的差异(单调队列)
给出一个包括N个元素的整数数组A,包括A本身在内,共有 (N+1)*N / 2个非空子段。例如:1 3 2的子段为{1} {3} {2} {1 3} {3 2} {1 3 2}。在这些子段中,如果最大值同最小值的差异不超过K,则认为这是一个合格的子段。给出数组A和K,求有多少符合条件的子段。例如:3 5 7 6 3,K = 2,符合条件的子段包括:{3} {5} {7} {6} {3} {3 5}...
2018-10-19 11:16:04 178
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人