結果

問題 No.2742 Car Flow
ユーザー rlangevinrlangevin
提出日時 2024-04-20 11:03:12
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 67 ms / 2,000 ms
コード長 155 bytes
コンパイル時間 727 ms
コンパイル使用メモリ 82,176 KB
実行使用メモリ 96,884 KB
最終ジャッジ日時 2024-04-20 11:03:17
合計ジャッジ時間 4,083 ms
ジャッジサーバーID
(参考情報)
judge5 / judge3
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 64 ms
96,424 KB
testcase_01 AC 65 ms
96,360 KB
testcase_02 AC 65 ms
95,900 KB
testcase_03 AC 66 ms
96,736 KB
testcase_04 AC 65 ms
96,884 KB
testcase_05 AC 67 ms
96,448 KB
testcase_06 AC 64 ms
96,876 KB
testcase_07 AC 64 ms
96,620 KB
testcase_08 AC 64 ms
95,940 KB
testcase_09 AC 63 ms
96,296 KB
testcase_10 AC 55 ms
85,576 KB
testcase_11 AC 57 ms
87,380 KB
testcase_12 AC 51 ms
81,812 KB
testcase_13 AC 48 ms
76,272 KB
testcase_14 AC 47 ms
75,088 KB
testcase_15 AC 37 ms
60,024 KB
testcase_16 AC 64 ms
95,472 KB
testcase_17 AC 63 ms
95,880 KB
testcase_18 AC 37 ms
60,216 KB
testcase_19 AC 64 ms
95,500 KB
testcase_20 AC 43 ms
68,528 KB
testcase_21 AC 41 ms
66,604 KB
testcase_22 AC 59 ms
88,056 KB
testcase_23 AC 59 ms
92,180 KB
testcase_24 AC 49 ms
76,224 KB
testcase_25 AC 64 ms
92,236 KB
testcase_26 AC 65 ms
96,560 KB
testcase_27 AC 43 ms
70,276 KB
testcase_28 AC 43 ms
72,696 KB
testcase_29 AC 36 ms
58,816 KB
testcase_30 AC 59 ms
91,064 KB
testcase_31 AC 39 ms
67,112 KB
testcase_32 AC 61 ms
91,432 KB
testcase_33 AC 62 ms
88,204 KB
testcase_34 AC 45 ms
73,148 KB
testcase_35 AC 40 ms
67,384 KB
testcase_36 AC 35 ms
58,896 KB
testcase_37 AC 42 ms
69,892 KB
testcase_38 AC 58 ms
88,708 KB
testcase_39 AC 38 ms
63,704 KB
testcase_40 AC 33 ms
52,500 KB
testcase_41 AC 32 ms
52,968 KB
testcase_42 AC 31 ms
52,120 KB
testcase_43 AC 33 ms
52,532 KB
testcase_44 AC 32 ms
52,820 KB
testcase_45 AC 32 ms
51,904 KB
testcase_46 AC 32 ms
52,460 KB
testcase_47 AC 32 ms
51,880 KB
testcase_48 AC 32 ms
53,160 KB
testcase_49 AC 32 ms
51,812 KB
testcase_50 AC 32 ms
52,644 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(input())
A = list(map(int, input().split()))
A = A
cnt = A.count(1)
ans = min(cnt, N - cnt)
mod = 998244353
print(ans * pow(N, mod - 2, mod) % mod)
0