結果

問題 No.741 AscNumber(Easy)
ユーザー tkr182
提出日時 2018-10-05 22:17:51
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
TLE  
実行時間 -
コード長 284 bytes
コンパイル時間 268 ms
コンパイル使用メモリ 12,416 KB
実行使用メモリ 17,440 KB
最終ジャッジ日時 2024-10-12 13:14:15
合計ジャッジ時間 5,242 ms
ジャッジサーバーID
(参考情報)
judge1 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 35 TLE * 1 -- * 19
権限があれば一括ダウンロードができます

ソースコード

diff #

n=int(input())
if n==1:
    print(10)
else:
    s=[1]*9
    c=10
    for i in range(1,n):
        for t in range(0,9):
            s[t]=sum(s[t:9])%(10**9+7)
        c+=sum(s)%(10**9+7)
    else:
        if c>=10**9+7:
            print(c%(10**9+7))
        else:
            print(c)
0