摘要: http://poj.org/problem?id=1050 Description Given a two-dimensional array of positive and negative integers, a sub-rectangle is any contiguous sub-arra 阅读全文
posted @ 2019-04-24 19:27 _Zlrrr 阅读(230) 评论(0) 推荐(0)
摘要: 解决区间查询最大值最小值的问题 用 $O(N * logN)$ 的复杂度预处理 查询的时候只要 $O(1)$ 的时间 这个算法是 real 小清新了 有一个长度为 N 的数组进行 M 次查询 可以查询区间最大值和最小值 阅读全文
posted @ 2019-04-24 16:03 _Zlrrr 阅读(240) 评论(0) 推荐(0)
摘要: A. Reverse a Substring 代码: #include <bits/stdc++.h> using namespace std; int N; string s; int main() { scanf("%d", &N); cin >> s; int temp = -1; for(i 阅读全文
posted @ 2019-04-24 14:06 _Zlrrr 阅读(208) 评论(0) 推荐(0)