Submission #203297

#TimeUsernameProblemLanguageResultExecution timeMemory
203297abra_stoneMeetings (JOI19_meetings)C++14
0 / 100
652 ms262148 KiB
#include "meetings.h" #define N 55 bool v[N][N][N]; int query(int p, int q, int r) { if (v[p][q][r]) return v[p][q][r]; v[p][q][r] = v[p][r][q] = v[q][p][r] = v[q][r][p] = v[r][p][q] = v[r][q][p] = Query(p, q, r); } void Solve(int n) { int i, j, k, t; for (i = 0; i < n; i++) { for (j = i + 1; j < n; j++) { for (k = 0; k < n; k++) { if (k == i || k == j) continue; t = query(i, j, k); if (t != i && t != j) break; } if (k == n) Bridge(i, j); } } }

Compilation message (stderr)

meetings.cpp: In function 'int query(int, int, int)':
meetings.cpp:9:1: warning: control reaches end of non-void function [-Wreturn-type]
 }
 ^
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...