版本比较
# 12.9星期二
正文
增加 3 行删除 3 行
36 行未改动37383940414243444597 行未改动14314414514614714814915015112 行未改动164165166167168169170171172146 行未改动全部展开36 行未改动}}}cout << ans;return 0;}```### 思路97 行未改动#include <bits/stdc++.h>using namespace std;#define int long longconst int maxn = 2e5 + 7;int a[maxn]; // 存储int ans = 0;priority_queue <int, vector<int>, less<int> >Q;signed main(){12 行未改动while (x--){op.push_back(Q.top());Q.pop();}ans += y;for (int i = 0; i < op.size(); i++){if (op[i] - y > 0)146 行未改动全部展开36 行未改动37383940414243444597 行未改动14314414514614714814915015112 行未改动164165166167168169170171172146 行未改动全部展开36 行未改动}}}cout << ans;return 0;}```### 思路97 行未改动#include <bits/stdc++.h>using namespace std;#define int long longconst int maxn = 2e5 + 7;int a[maxn]; // 存储int ans = 0;priority_queue <int, vector<int>, less<int> >Q;signed main(){12 行未改动while (x--){op.push_back(Q.top());Q.pop();}ans += y;for (int i = 0; i < op.size(); i++){if (op[i] - y > 0)146 行未改动全部展开