# | 제출 시각UTC-0 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
133555 | tlwpdus | Friends (BOI17_friends) | C++11 | 773 ms | 20992 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include <bits/stdc++.h>
using namespace std;
typedef pair<int,int> pii;
int n, p, q;
vector<int> lis[3000];
int mat[3000][3000];
void pung() {
puts("detention");
exit(0);
}
int gn;
int grp[3000][3000], gs[3000];
int chk[3000], inc[3000];
int sel[3000], cand[3000];
int sb, cb;
bool bt(int nq, int dep) {
if (sb<=p&&nq<=q) return true;
if (dep>=p+q||!cb||cb+sb>p+q) return false;
int v = cand[--cb]; inc[v] = 0; chk[v] = 0;
if (bt(nq,dep+1)) {
chk[v] = -1;
inc[v] = 0;
return true;
}
sel[sb++] = v; chk[v] = 1;
컴파일 시 표준 에러 (stderr) 메시지
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |