提出 #6459937


ソースコード 拡げる

Copy
#include <bits/stdc++.h>
using namespace std;


int main() {
	int n; cin >> n;
	multiset<int> s;

	for (int i = 0; i < n; i++) {
		int a; cin >> a;
		auto it = s.upper_bound(-a);
		if (it == s.end()) s.insert(-a);
		else {
			s.erase(it);
			s.insert(-a);
		}
	}
	
	cout << s.size() << endl;

	return 0;
}

提出情報

提出日時
問題 E - Sequence Decomposing
ユーザ Nachia
言語 C# (Mono 4.6.2.0)
得点 0
コード長 330 Byte
結果 CE

コンパイルエラー

./Main.cs(3,0): error CS1024: Wrong preprocessor directive
./Main.cs(3,6): error CS1525: Unexpected symbol `namespace', expecting `identifier' or `static'
./Main.cs(3,19): error CS1525: Unexpected symbol `;', expecting `identifier' or `static'
./Main.cs(7,1): error CS1525: Unexpected symbol `int', expecting `identifier' or `static'
./Main.cs(11,2): error CS1525: Unexpected symbol `int', expecting `identifier' or `static'
./Main.cs(12,25): error CS1525: Unexpected symbol `(', expecting `identifier' or `static'
./Main.cs(13,17): error CS1525: Unexpected symbol `(', expecting `identifier' or `static'
./Main.cs(13,29): error CS1525: Unexpected symbol `(', expecting `identifier' or `static'
./Main.cs(15,3): error CS1525: Unexpected symbol `s', expecting `identifier' or `static'
./Main.cs(15,10): error CS1525: Unexpected symbol `(', expecting `identifier' or `static'
./Main.cs(16,11): error CS1525: Unexpected symbol `(', expecting `identifier' or `static'
./Main.cs(17,3): error CS1514: Unexpected symbol `}', expect...