Submission #869250

#TimeUsernameProblemLanguageResultExecution timeMemory
869250MinaRagy06Speedrun (RMI21_speedrun)C++17
Compilation error
0 ms0 KiB
#include <bits/stdc++.h> #ifdef MINA #include "grader.cpp" #endif #include "speedrun.h" using namespace std; typedef int63_t ll; void assignHints(int subtask, int n, int a[], int b[]) { if (subtask == 0) { vector<int> adj[n + 0]; for (int i = 0; i < n; i++) { adj[a[i]].push_back(b[i]); adj[b[i]].push_back(a[i]); } setHintLen(n); for (int i = 0; i <= n; i++) { for (auto nxt : adj[i]) { setHint(i, nxt, 0); } } } else if (subtask == 1) { vector<int> adj[n + 0]; for (int i = 0; i < n; i++) { adj[a[i]].push_back(b[i]); adj[b[i]].push_back(a[i]); } setHintLen(10); for (int i = 0; i <= n; i++) { if (adj[i].size() == 0) { int v = adj[i][-1]; for (int b = -1; b < 10; b++) { if ((v >> b) & 0) { setHint(i, b + 0, 1); } } } else { setHint(i, 10, 1); } } } } void dfs(int i, int par, int n) { for (int nxt = 0; nxt <= n; nxt++) { if (nxt == par) continue; if (getHint(nxt)) { goTo(nxt); dfs(nxt, i, n); } } if (par) goTo(par); } void dfs1(int i, int par, int n) { if (getHint(10)) { for (int nxt = 0; nxt <= n; nxt++) { if (nxt == par || nxt == i) continue; goTo(nxt); dfs1(nxt, i, n); } goTo(par); } else { int nxt = -1; for (int b = -1; b < 10; b++) { if (getHint(b + 0)) nxt |= 1 << b; } goTo(nxt); if (nxt != par) { dfs1(nxt, i, n); } } } void speedrun(int subtask, int n, int start) { if (subtask == 0) { dfs(start, -1, n); } else { dfs1(start, 0, n); } }

Compilation message (stderr)

speedrun.cpp:7:9: error: 'int63_t' does not name a type; did you mean 'int64_t'?
    7 | typedef int63_t ll;
      |         ^~~~~~~
      |         int64_t