結果

問題 No.1972 Modulo Set
ユーザー tailstails
提出日時 2022-06-10 21:34:48
言語 cLay
(20240104-1)
結果
WA  
実行時間 -
コード長 131 bytes
コンパイル時間 3,622 ms
コンパイル使用メモリ 182,264 KB
実行使用メモリ 16,784 KB
最終ジャッジ日時 2023-10-21 04:54:28
合計ジャッジ時間 6,850 ms
ジャッジサーバーID
(参考情報)
judge11 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 1 ms
4,348 KB
testcase_01 AC 2 ms
4,348 KB
testcase_02 AC 2 ms
4,348 KB
testcase_03 WA -
testcase_04 WA -
testcase_05 WA -
testcase_06 WA -
testcase_07 WA -
testcase_08 WA -
testcase_09 AC 3 ms
4,348 KB
testcase_10 WA -
testcase_11 WA -
testcase_12 WA -
testcase_13 AC 6 ms
4,348 KB
testcase_14 AC 6 ms
4,348 KB
testcase_15 WA -
testcase_16 AC 95 ms
8,560 KB
testcase_17 AC 24 ms
5,272 KB
testcase_18 AC 2 ms
4,348 KB
testcase_19 AC 79 ms
8,376 KB
testcase_20 WA -
testcase_21 WA -
testcase_22 AC 66 ms
8,052 KB
testcase_23 AC 194 ms
14,784 KB
testcase_24 AC 48 ms
8,256 KB
testcase_25 AC 88 ms
10,612 KB
testcase_26 WA -
testcase_27 AC 209 ms
15,412 KB
testcase_28 AC 54 ms
8,420 KB
testcase_29 AC 94 ms
10,796 KB
testcase_30 AC 144 ms
13,424 KB
testcase_31 AC 5 ms
4,348 KB
testcase_32 AC 124 ms
12,528 KB
testcase_33 AC 234 ms
16,784 KB
testcase_34 AC 248 ms
16,776 KB
testcase_35 AC 244 ms
16,780 KB
testcase_36 AC 237 ms
16,780 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

map<ll,ll>b;
ll@n,@m,@a[n],z=0;
rep(i,n)++b[a[i]%=m];
rep(i,n)
	z+=a[i]*2%m?max(b[a[i]],b[m-a[i]]):1,
	b[a[i]]=b[m-a[i]]=0;
wt(z);
0