Submission #1106232

#TimeUTC-0UsernameProblemLanguageResultExecution timeMemory
11062322024-10-29 15:27:19cabbitRobot (JOI21_ho_t4)C++14
0 / 100
585 ms74428 KiB
#include <bits/stdc++.h>
using namespace std;
#ifdef LOCAL
#include "debug.h"
#else
#define debug(...) 42
#endif
const int N = 1e5 + 5, MAX = 5e5 + 5;
const long long inf = 1e18;
int n, m;
long long d[MAX], sum[MAX];
map<array<int, 2>, long long> mp;
vector<pair<int, long long>> g[MAX];
int main() {
ios::sync_with_stdio(false); cin.tie(nullptr);
cin >> n >> m;
int tot = n;
auto add = [&](int u, int c) {
if (!mp.count({u, c})) {
mp[{u, c}] = ++tot;
}
return mp[{u, c}];
};
for (int i = 1; i <= m; ++i) {
 
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Compilation message (stderr)

Main.cpp: In function 'int main()':
Main.cpp:39:13: warning: structured bindings only available with '-std=c++17' or '-std=gnu++17'
   39 |   for (auto [dat, u] : mp) {
      |             ^
Main.cpp:41:16: warning: structured bindings only available with '-std=c++17' or '-std=gnu++17'
   41 |     for (auto &[v, w] : g[u]) {
      |                ^
Main.cpp:50:10: warning: structured bindings only available with '-std=c++17' or '-std=gnu++17'
   50 |     auto [c, u] = pq.top(); pq.pop();
      |          ^
Main.cpp:54:15: warning: structured bindings only available with '-std=c++17' or '-std=gnu++17'
   54 |     for (auto [v, w] : g[u]) {
      |               ^
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...