Submission #672398

#TimeUsernameProblemLanguageResultExecution timeMemory
672398horiseunZagrade (COI20_zagrade)C++11
Compilation error
0 ms0 KiB
#include "cia.h" #include <iostream> #include <stack> #include <cstring> using namespace std; stack<int> unpaired; char s[100005]; int count; string solve(int n, int q) { unpaired.push(0); for (int i = 1; i < n; i++) { if (unpaired.empty()) { unpaired.push(i); continue; } if (query(unpaired.top(), i)) { s[unpaired.top()] = '('; s[i] = ')'; unpaired.pop(); } else { unpaired.push(i); } } for (int i = 0; i < n; i++) { if (!(s[i] == ')' || s[i] == '(')) count++; } count /= 2; string ans = ""; for (int i = 0; i < n; i++) { if (s[i] == ')' || s[i] == '(') { ans += s[i]; } else { if (count) { ans += ')'; count--; } else { ans += '('; } } } return ans; }

Compilation message (stderr)

zagrade.cpp:1:10: fatal error: cia.h: No such file or directory
    1 | #include "cia.h"
      |          ^~~~~~~
compilation terminated.