Submission #1295359

#TimeUsernameProblemLanguageResultExecution timeMemory
1295359lambd47Question (Grader is different from the original contest) (CEOI14_question_grader)C++20
100 / 100
701 ms39744 KiB
#include<bits/stdc++.h> using namespace std; int xx=0; vector<int> mapa; int encode (int n, int x, int y) { if(xx==0){ for(int i=0;i<(1<<12);i++){ if(__builtin_popcount(i)==6){ mapa.push_back(i); } } } xx++; for(int i=0;i<12;i++){ if(((1<<i)&mapa[x])>0 && (((1<<i)&(mapa[y]))==0)){ return i+1; } } }
#include<bits/stdc++.h> using namespace std; vector<int> mapa; int xx=0; int decode (int n, int x, int h) { if(xx==0){ for(int i=0;i<(1<<12);i++){ if(__builtin_popcount(i)==6){ mapa.push_back(i); } } } xx++; h--; if(mapa[x]&(1<<h)){ return 1; } else return 0; }

Compilation message (stderr)

# 1번째 컴파일 단계

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