版本比较
day1
正文
增加 3 行删除 3 行
57 行未改动5859606162626364646566676857 行未改动12612712812913013013113213313426 行未改动57 行未改动 tr[u].sum -= 1ll * tr[u].cnt * (tr[u].mx - v); tr[u].mx = v;}void pushdown(int u) { if (tr[u].mx < tr[ls].mx) if (tr[u].mx < tr[ls].mx) addtag(ls, tr[u].mx); if (tr[u].mx < tr[rs].mx) if (tr[u].mx < tr[rs].mx) addtag(rs, tr[u].mx);}void build(int u, int L, int R) { if (L == R) {57 行未改动
int main() { ios::sync_with_stdio(0); cin.tie(0); cout.tie(0); int t; int t; cin >> t; while (t -- ) solve(); return 0;}26 行未改动