結果

問題 No.657 テトラナッチ数列 Easy
ユーザー DexctersuDexctersu
提出日時 2018-03-19 23:43:58
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
RE  
実行時間 -
コード長 164 bytes
コンパイル時間 453 ms
コンパイル使用メモリ 10,696 KB
実行使用メモリ 8,848 KB
最終ジャッジ日時 2023-09-02 14:08:36
合計ジャッジ時間 1,796 ms
ジャッジサーバーID
(参考情報)
judge14 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 21 ms
7,904 KB
testcase_01 AC 21 ms
7,732 KB
testcase_02 AC 20 ms
7,972 KB
testcase_03 AC 20 ms
7,820 KB
testcase_04 RE -
testcase_05 AC 45 ms
8,532 KB
testcase_06 AC 21 ms
7,916 KB
testcase_07 AC 20 ms
7,808 KB
testcase_08 RE -
testcase_09 AC 45 ms
8,780 KB
testcase_10 AC 45 ms
8,848 KB
testcase_11 AC 45 ms
8,844 KB
testcase_12 RE -
testcase_13 RE -
testcase_14 RE -
testcase_15 RE -
権限があれば一括ダウンロードができます

ソースコード

diff #

q=int(input())
n=[int(input())for i in range(q)]
a=10**4
t=[0]*a
t[3]=1
for i in range(4,a):
    t[i]=(t[i-4]+t[i-3]+t[i-2]+t[i-1])%17
for j in n:
    print(t[j-1])
0