# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
61953 | 2018-07-27T06:24:48 Z | 김현수(#2139) | popa (BOI18_popa) | C++11 | 1000 ms | 436 KB |
#include<bits/stdc++.h> #include"popa.h" using namespace std; int solve (int N, int *Left, int *Right) { for(int i=0;i<N;i++) { Left[i] = Right[i] = -1; } vector<int> S; S.push_back(N); for(int i=1;i<N;i++) { int P = 0; while(!S.empty()) { int T = S.back(); if(Right[T] != -1) continue; if(query(T, T, T, i)) { Right[T] = i; break; } else S.pop_back(); } if(S.empty()) { Left[i] = P; } S.push_back(i); } }
Compilation message
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Execution timed out | 1047 ms | 248 KB | Time limit exceeded |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Execution timed out | 1060 ms | 436 KB | Time limit exceeded |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Execution timed out | 1048 ms | 436 KB | Time limit exceeded |
2 | Halted | 0 ms | 0 KB | - |