結果
問題 | No.1964 sum = length |
ユーザー | harurun |
提出日時 | 2022-04-21 19:24:20 |
言語 | PyPy3 (7.3.15) |
結果 |
WA
|
実行時間 | - |
コード長 | 377 bytes |
コンパイル時間 | 314 ms |
コンパイル使用メモリ | 87,260 KB |
実行使用メモリ | 76,828 KB |
最終ジャッジ日時 | 2023-09-05 02:44:57 |
合計ジャッジ時間 | 11,678 ms |
ジャッジサーバーID (参考情報) |
judge11 / judge14 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 72 ms
71,412 KB |
testcase_01 | AC | 73 ms
71,352 KB |
testcase_02 | WA | - |
testcase_03 | AC | 73 ms
71,384 KB |
testcase_04 | AC | 73 ms
70,960 KB |
testcase_05 | AC | 72 ms
71,328 KB |
testcase_06 | AC | 69 ms
71,096 KB |
testcase_07 | AC | 71 ms
71,380 KB |
testcase_08 | AC | 73 ms
71,452 KB |
testcase_09 | AC | 78 ms
76,404 KB |
testcase_10 | AC | 77 ms
75,832 KB |
testcase_11 | WA | - |
testcase_12 | WA | - |
testcase_13 | WA | - |
testcase_14 | WA | - |
testcase_15 | WA | - |
testcase_16 | WA | - |
testcase_17 | WA | - |
testcase_18 | WA | - |
testcase_19 | WA | - |
testcase_20 | WA | - |
testcase_21 | WA | - |
testcase_22 | WA | - |
testcase_23 | WA | - |
testcase_24 | WA | - |
testcase_25 | WA | - |
testcase_26 | WA | - |
testcase_27 | WA | - |
testcase_28 | WA | - |
testcase_29 | WA | - |
testcase_30 | WA | - |
testcase_31 | WA | - |
testcase_32 | WA | - |
testcase_33 | WA | - |
testcase_34 | WA | - |
testcase_35 | WA | - |
testcase_36 | WA | - |
testcase_37 | WA | - |
testcase_38 | WA | - |
testcase_39 | WA | - |
testcase_40 | WA | - |
testcase_41 | WA | - |
testcase_42 | WA | - |
ソースコード
def main(): n=int(input()) C=[0]*(2*n) a=1 d=0 while a-d<2*n: C[a-d]+=1 if a%10==0: d+=1 a+=1 mod=998244353 dp=[0]*(2*n) dp[0]=1 for i in range(n): dp2=[0]*(2*n) for j in range(2*n): for k in range(1,2*n): if j+k<2*n: dp2[j+k]+=dp[j]*C[k] dp2[j+k]%=mod dp=dp2 print(dp[2*n-1]) return main()