제출 #499479

#제출 시각아이디문제언어결과실행 시간메모리
499479Ghazal_DwaiKamenčići (COCI21_kamencici)C++14
컴파일 에러
0 ms0 KiB
#include <bits/stdc++.h> using namespace std; int main(){ int n,k; string s; cin>>n>>k; cin>>s; int an=0,br=0; int x=n; while(x--){ for(int i=0;i<=n;i++){ for(int j=n-1;j<=0;j++){ if(s[i]=='c'&&s[j]=='c'){ if(x%2==1){ an++; } else{ br++; } } if(an>=k){ cout<<"NE"; } else{ if(br>=k){ cout<<"DA"; } } } } } } return 0; }

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

Main.cpp:38:5: error: expected unqualified-id before 'return'
   38 |     return 0;
      |     ^~~~~~
Main.cpp:39:1: error: expected declaration before '}' token
   39 | }
      | ^