제출 #227628

#제출 시각아이디문제언어결과실행 시간메모리
227628bensonlzlBaloni (COCI15_baloni)C++14
컴파일 에러
0 ms0 KiB
#include <bits/stdc++.h>

using namespace std;

int N, H[1000005], arrow[1000005], tot = 0;

int main(){
	ios_base::sync_with_stdio(false);
	cin.tie(0);
	cin >> N;
	for (int i = 1; i <= N; ++i){
		cin >> H[i];
		if (!arrow[H[i]]){
			tot++;
			arrow[H[i]-1]++;
		}
		else{
			arrow[H[i]]--;
			arrow[H[i]-1]++
		}
	}
	cout << tot << '\n';
}

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

baloni.cpp: In function 'int main()':
baloni.cpp:20:3: error: expected ';' before '}' token
   }
   ^