版本比较
Atcoder ABC437游记
正文
增加 16 行删除 16 行
1233456724 行未改动3233343536363738394019 行未改动6061626364646566676819 行未改动8889909192929394959659 行未改动15615715815916016016116216316432 行未改动19719819920020120120220320420520620720820921021121121221321421531 行未改动24724824925025125125225325425513 行未改动26927027127227327327427527627727827928028128128228328428528628728828929029029129229329421 行未改动31631731831932032032132232332432532632732832933033133233333033133233333433533633770 行未改动上一场没写因为实在太唐了,但这场挺难的,rating给我 $\pm 0$ 就很尴尬,差两分上蓝。
--- ---
# 题目
## 题目评级24 行未改动}```
--- ---
## B.Tombola
### 题目描述19 行未改动 int n, m; cin >> n >> m; int T; cin >> T;
vector<vector<int>> a(n, vector<int>(m)); for (int i = 0; i < n; i++) { for (int j = 0; j < m; j++) { cin >> a[i][j];19 行未改动}```
--- ---
## C.Reindeer and Sleigh 2
### 题目描述59 行未改动
```
--- ---
## D.Sun of Differences
### 题目描述32 行未改动 } int ans = 0; for (int i = 0; i < n; i++) { int pos = upper_bound(b.begin(), b.end(), a[i]) - b.begin(); ans = ((ans + (((pos * a[i]) % mod - pre[pos]) % mod + mod) % mod) % mod + ans = ((ans + (((pos * a[i]) % mod - pre[pos]) % mod + mod) % mod) % mod + ((pre[m] - pre[pos] + mod) % mod - ((m - pos) * a[i]) % mod + mod) % mod) % mod; } cout << ans; return 0;}
```
--- ---
## E.Sort Arrays
### 题目描述31 行未改动using namespace std;#define int long longstruct node{ map<int, int> edges; map<int, int> edges; vector<int> idx;}trie[333333];void dfs(int x, vector<int>& ans){13 行未改动 pos[0] = 0; for (int i = 1; i <= n; i++) { int x, y; cin >> x >> y; int u = pos[x]; int u = pos[x]; if (trie[u].edges.find(y) == trie[u].edges.end()) { trie[u].edges[y] = ++cnt; } pos[i] = trie[u].edges[y]; trie[trie[u].edges[y]].idx.push_back(i); } vector<int> ans; dfs(0, ans); dfs(0, ans); for (int i = 0; i < ans.size(); i++) { cout << ans[i] << ' '; } return 0;}```
--- ---
## F.Manhattan Chirstmas Tree 2
21 行未改动#define int long longstruct node{ int mx1, mx2, mn1, mn2; node() : mx1(LLONG_MAX), mx2(LLONG_MIN), mn1(LLONG_MAX), mn2(LLONG_MIN) {} node() : mx1(LLONG_MAX), mx2(LLONG_MIN), mn1(LLONG_MAX), mn2(LLONG_MIN) {} node(int x, int y) { mx1 = mx2 = x + y; mn1 = mn2 = x - y; }}bit[200005 << 2];int n;node merge(node a, node b){ node res; res.mx1 = min(a.mx1, b.mx1); res.mx2 = max(a.mx2, b.mx2); res.mn1 = min(a.mn1, b.mn1); res.mn2 = max(a.mn2, b.mn2); res.mx1 = min(a.mx1, b.mx1); res.mx2 = max(a.mx2, b.mx2); res.mn1 = min(a.mn1, b.mn1); res.mn2 = max(a.mn2, b.mn2); return res;}vector<int> a, b;void build(int x, int L, int R)70 行未改动