Submission #676955

#TimeUsernameProblemLanguageResultExecution timeMemory
676955Spade1Cluedo (IOI10_cluedo)C++14
100 / 100
12 ms292 KiB
#include<bits/stdc++.h>
#define pii pair<int, int>
#define pII pair<pii, pii>
#define pll pair<long long, long long>
#define ll long long
#define ld long double
#define st first
#define nd second
#define pb push_back
#define INF INT_MAX
#include "grader.h"
#include "cluedo.h"

using namespace std;

void Solve(){
    int a=1, b=1, c=1;
    int w;
    while (w = Theory(a, b, c)) {
        if (w==1) a++;
        if (w==2) b++;
        if (w==3) c++;
    }
    return;
}

Compilation message (stderr)

cluedo.cpp: In function 'void Solve()':
cluedo.cpp:19:14: warning: suggest parentheses around assignment used as truth value [-Wparentheses]
   19 |     while (w = Theory(a, b, c)) {
      |            ~~^~~~~~~~~~~~~~~~~
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...