Submission #655041

#TimeUsernameProblemLanguageResultExecution timeMemory
655041hyakupMemory (IOI10_memory)C++17
100 / 100
2 ms292 KiB
#include "grader.h" #include "memory.h" #include <bits/stdc++.h> using namespace std; const int maxn = 55; int cont[maxn]; int pos1[maxn], pos2[maxn]; void play() { for( int i = 1; i <= 25; i++){ char c1, c2; c1 = faceup(2*i - 1); cont[ c1 - 'A' ]++; if( cont[ c1 - 'A' ] == 1 ) pos1[ c1 - 'A' ] = 2*i - 1; else pos2[ c1 - 'A' ] = 2*i - 1; c2 = faceup(2*i); cont[ c2 - 'A' ]++; if( cont[ c2 - 'A' ] == 1 ) pos1[ c2 - 'A' ] = 2*i; else pos2[ c2 - 'A' ] = 2*i; } for( int i = 0; i < 25; i++ ){ char c1, c2; c1 = faceup( pos1[i] ); c2 = faceup( pos2[i] ); } }

Compilation message (stderr)

memory.cpp: In function 'void play()':
memory.cpp:35:8: warning: variable 'c1' set but not used [-Wunused-but-set-variable]
   35 |   char c1, c2;
      |        ^~
memory.cpp:35:12: warning: variable 'c2' set but not used [-Wunused-but-set-variable]
   35 |   char c1, c2;
      |            ^~
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...