제출 #742395

#제출 시각아이디문제언어결과실행 시간메모리
742395jamielimFlight to the Ford (BOI22_communication)C++17
컴파일 에러
0 ms0 KiB
#include "communication.h" #include <bits/stdc++.h> using namespace std; #define fi first #define se second #define mp make_pair #define pb emplace_back #define ALL(x) x.begin(),x.end() #define SZ(x) (int)x.size() typedef long long ll; typedef pair<int,int> ii; typedef pair<ii,ii> i4; typedef vector<int> vi; const int MOD=1000000007; const int INF=1012345678; const ll LLINF=1012345678012345678LL; const double PI=3.1415926536; const double EPS=1e-14; void encode(int N, int X) { if(X==1){ if(send(0)!=0)send(0); // 0 or 10 for(int i=0;i<9;i++){ if(send(0)!=0){ send(1); // [000...0]11 } } }else{ if(send(1)!=1)send(1); // 1 or 01 for(int i=0;i<9;i++){ if(send(1)!=1){ send(0); // [111...1]00 } } } } pair<int, int> decode(int N) { int x=receive(); int y=receive(); whlie(x!=y){ x=y; y=receive(); } if(x==1)return {1,1}; return {2,3}; }

컴파일 시 표준 에러 (stderr) 메시지

communication.cpp: In function 'std::pair<int, int> decode(int)':
communication.cpp:42:2: error: 'whlie' was not declared in this scope
   42 |  whlie(x!=y){
      |  ^~~~~