Submission #717634

# Submission time Handle Problem Language Result Execution time Memory
717634 2023-04-02T10:00:57 Z VMaksimoski008 Cluedo (IOI10_cluedo) C++14
Compilation error
0 ms 0 KB
#include "grader.h"
#include "cluedo.h"
#include <set>

void Solve(){
   int r;

   std::set<int> mur, place, weapon;

   for(int i=1; i<=6; i++)
   {
       for(int j=1; j<=10; j++)
       {
           for(int k=1; k<=6; k++)
           {
               if(mur.count(i) == 0 && place.count(j) == 0 && weapon.count(k))
               {
                   r = Theory(i, j, k);
                   if(r == 1) mur.insert(i);
                   else if(r == 2) place.insert(j);
                   else if(r == 3) wepaon.insert(k);
                   else if(r == 0) return ;
               }
           }
       }
   }
}

Compilation message

cluedo.cpp: In function 'void Solve()':
cluedo.cpp:21:36: error: 'wepaon' was not declared in this scope; did you mean 'weapon'?
   21 |                    else if(r == 3) wepaon.insert(k);
      |                                    ^~~~~~
      |                                    weapon