結果

問題 No.759 悪くない忘年会にしような!
ユーザー tailstails
提出日時 2018-12-07 00:52:02
言語 cLay
(20240104-1)
結果
WA  
実行時間 -
コード長 448 bytes
コンパイル時間 3,521 ms
コンパイル使用メモリ 182,508 KB
実行使用メモリ 9,280 KB
最終ジャッジ日時 2023-09-19 00:10:32
合計ジャッジ時間 7,212 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
5,940 KB
testcase_01 AC 2 ms
5,948 KB
testcase_02 AC 2 ms
6,112 KB
testcase_03 AC 3 ms
5,964 KB
testcase_04 AC 2 ms
5,912 KB
testcase_05 AC 3 ms
6,176 KB
testcase_06 AC 2 ms
6,040 KB
testcase_07 AC 2 ms
5,936 KB
testcase_08 AC 2 ms
5,908 KB
testcase_09 AC 2 ms
5,964 KB
testcase_10 AC 2 ms
5,932 KB
testcase_11 AC 3 ms
5,976 KB
testcase_12 AC 2 ms
5,956 KB
testcase_13 AC 2 ms
5,908 KB
testcase_14 AC 3 ms
5,964 KB
testcase_15 AC 2 ms
6,212 KB
testcase_16 AC 2 ms
5,912 KB
testcase_17 AC 3 ms
5,992 KB
testcase_18 AC 2 ms
5,904 KB
testcase_19 AC 2 ms
5,912 KB
testcase_20 AC 3 ms
5,904 KB
testcase_21 AC 3 ms
5,948 KB
testcase_22 AC 3 ms
5,916 KB
testcase_23 AC 2 ms
5,908 KB
testcase_24 AC 2 ms
6,028 KB
testcase_25 AC 3 ms
6,140 KB
testcase_26 AC 2 ms
5,980 KB
testcase_27 AC 3 ms
5,904 KB
testcase_28 AC 3 ms
5,964 KB
testcase_29 AC 2 ms
5,940 KB
testcase_30 AC 2 ms
5,936 KB
testcase_31 AC 2 ms
5,908 KB
testcase_32 AC 2 ms
6,216 KB
testcase_33 AC 5 ms
6,384 KB
testcase_34 AC 3 ms
5,948 KB
testcase_35 AC 4 ms
6,056 KB
testcase_36 WA -
testcase_37 AC 3 ms
6,144 KB
testcase_38 WA -
testcase_39 AC 3 ms
6,140 KB
testcase_40 AC 4 ms
6,292 KB
testcase_41 WA -
testcase_42 WA -
testcase_43 WA -
testcase_44 WA -
testcase_45 WA -
testcase_46 WA -
testcase_47 WA -
testcase_48 WA -
testcase_49 WA -
testcase_50 WA -
testcase_51 WA -
testcase_52 AC 5 ms
6,248 KB
testcase_53 WA -
testcase_54 WA -
testcase_55 WA -
testcase_56 WA -
testcase_57 WA -
testcase_58 WA -
testcase_59 WA -
testcase_60 WA -
testcase_61 WA -
testcase_62 WA -
testcase_63 WA -
testcase_64 WA -
testcase_65 WA -
testcase_66 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

int n;
int ap[101010],at[101010],ar[101010],ai[101010],alive[101010];

bool cmp(int a,int b){
	return
	ap[a]>ap[b]?:ap[a]<ap[b]?0:
	at[a]>at[b]?:at[a]<at[b]?0:
	ar[a]>ar[b];
}

{
	rd(n,(ap,at,ar)(n));
	ai[0..n]=(0..);
	std::sort(ai,ai+n,cmp);
	segtree<int> t;
	t.malloc(1d4+1,1);
	for(int j=0;j<n;++j){
		int i=ai[j];
		if(t.getMinVal(at[i],1d4)+1>-ar[i]){
			alive[i]=1;
			t.change(at[i],at[i]+1,-ar[i]-1);
		}
	}
	rep(i,n)if(alive[i])wt(i+1);
}
0