摘要:
1. 排一次序后就可以得到答案 2. 排一次序只能得到这次的最优选择,需要多次排序,得到全部的最优答案 阅读全文
摘要:
"题目描述" 思路 代码 c++ include int n, ans, pre; bool rec[1000006]; struct Node { int a, b; } arr[1000006], tmp; void qsort(int L, int R) { int l = L, r = R; 阅读全文
摘要:
"题目描述" 思路 代码 c++ include int n, ans, pre; struct Node { int a, b; } arr[1000006], tmp; inline int read() { int s = 0, f = 1; char ch = getchar(); whil 阅读全文
摘要:
"题目描述" 思路 代码 c++ include include include using namespace std; int n, arr[50005], save[50005]; int tmp[50005]; long long maxx, minn; const int inf = 0x 阅读全文