This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <iostream>
#include <string.h>
#include "grader.h"
#include "cluedo.h"
using namespace std;
bool m[10] , l[15] , w[10] ;
void Solve () {
memset(m,0,sizeof(m));memset(l,0,sizeof(l));memset(w,0,sizeof(w));
for(int i=1;i<=6;i++) {
if (m[i]) continue;
for (int j=1;j<=10;j++) {
if (m[i]||l[j]) continue;
for (int x=1;x<=6;x++) {
if (m[i]||l[j]||w[x]) continue;
int y = Theory(i,j,x);
if (y==0) return;
if (y==1) m[i] = true ;
if (y==2) l[j] = true ;
if (y==3) w[x] = true ;
}
}
}
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |