結果

問題 No.231 めぐるはめぐる (1)
ユーザー zaichuzaichu
提出日時 2015-12-16 18:42:41
言語 C++11
(gcc 11.4.0)
結果
WA  
実行時間 -
コード長 471 bytes
コンパイル時間 492 ms
コンパイル使用メモリ 67,164 KB
実行使用メモリ 4,356 KB
最終ジャッジ日時 2023-10-14 10:50:48
合計ジャッジ時間 2,026 ms
ジャッジサーバーID
(参考情報)
judge12 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
4,352 KB
testcase_01 AC 2 ms
4,348 KB
testcase_02 AC 2 ms
4,352 KB
testcase_03 WA -
testcase_04 WA -
testcase_05 AC 1 ms
4,348 KB
testcase_06 WA -
testcase_07 WA -
testcase_08 WA -
testcase_09 AC 2 ms
4,348 KB
testcase_10 AC 2 ms
4,352 KB
testcase_11 AC 2 ms
4,348 KB
testcase_12 AC 2 ms
4,348 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

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

int main(){
	int n;
	cin >> n;
	vector<int> G(n);
	int x,y;
	int total = 0;
	for(int i = 0; i < n; i++){
		cin >> x >> y;
		G[i] = x-(30000*y);
	}
	sort(G.begin(),G.end());
	for(int i = 0; i < 6; i++) total += G[n-1];
	if(total >= 3000000){
		cout << "YES" << endl;
		for(int i = 0; i < 6; i++){
			cout << n << endl;
		}
	}else{
		cout << "NO" << endl;
	}
	return 0;
}		
0