Submission #2177986


Source Code Expand

#include <algorithm>
#include <iostream>
using namespace std;

int main(){
	int N, F[1000];
	for(int i=0; i<1000; i++){
		F[i] = 0;
	}
	cin >> N;
	for(int i=0; i<N; i++){
		cin >> int A;
		F[A-1] = A;
	}
	sort(F, F+1000);
	cout << F[998] << endl;
}

Submission Info

Submission Time
Task B - 心配性な富豪、ファミリーレストランに行く。
User gobeyond
Language C++14 (GCC 5.4.1)
Score 0
Code Size 264 Byte
Status CE

Compile Error

./Main.cpp: In function ‘int main()’:
./Main.cpp:12:10: error: expected primary-expression before ‘int’
   cin >> int A;
          ^
./Main.cpp:13:5: error: ‘A’ was not declared in this scope
   F[A-1] = A;
     ^