結果

問題 No.2770 Coupon Optimization
ユーザー tailstails
提出日時 2024-06-04 11:19:33
言語 cLay
(20240420-1)
結果
WA  
実行時間 -
コード長 176 bytes
コンパイル時間 6,069 ms
コンパイル使用メモリ 208,012 KB
実行使用メモリ 8,832 KB
最終ジャッジ日時 2024-06-04 11:19:42
合計ジャッジ時間 7,127 ms
ジャッジサーバーID
(参考情報)
judge1 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 AC 2 ms
5,376 KB
testcase_03 AC 26 ms
7,168 KB
testcase_04 AC 27 ms
7,040 KB
testcase_05 AC 3 ms
5,376 KB
testcase_06 WA -
testcase_07 WA -
testcase_08 WA -
testcase_09 WA -
testcase_10 WA -
testcase_11 WA -
testcase_12 WA -
testcase_13 WA -
testcase_14 WA -
testcase_15 WA -
testcase_16 WA -
testcase_17 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

ll@n,@m,@a[n],h[100]{},z=0;
a[0..n-1]/=100;
sortA(n,a);
rep(m){
	ll@b;
	h[100-b]++;
}
rep(k,n){
	int d=k;
	rep(j,100){
		d-=h[j];
		if(d>=0){
			z+=a[k-h[j]];
		}
	}
	wt(z);
}
0