結果

問題 No.2600 Avator Height
ユーザー minimumminimum
提出日時 2024-01-12 21:27:20
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 591 ms / 2,000 ms
コード長 250 bytes
コンパイル時間 551 ms
コンパイル使用メモリ 81,572 KB
実行使用メモリ 103,504 KB
最終ジャッジ日時 2024-01-12 21:28:06
合計ジャッジ時間 17,078 ms
ジャッジサーバーID
(参考情報)
judge13 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 62 ms
89,340 KB
testcase_01 AC 531 ms
103,500 KB
testcase_02 AC 531 ms
103,500 KB
testcase_03 AC 546 ms
103,500 KB
testcase_04 AC 529 ms
103,500 KB
testcase_05 AC 527 ms
103,500 KB
testcase_06 AC 529 ms
103,500 KB
testcase_07 AC 562 ms
103,500 KB
testcase_08 AC 539 ms
103,500 KB
testcase_09 AC 538 ms
103,500 KB
testcase_10 AC 540 ms
103,500 KB
testcase_11 AC 535 ms
103,500 KB
testcase_12 AC 526 ms
103,500 KB
testcase_13 AC 534 ms
103,500 KB
testcase_14 AC 563 ms
103,500 KB
testcase_15 AC 543 ms
103,500 KB
testcase_16 AC 542 ms
103,500 KB
testcase_17 AC 545 ms
103,500 KB
testcase_18 AC 532 ms
103,500 KB
testcase_19 AC 552 ms
103,500 KB
testcase_20 AC 568 ms
103,500 KB
testcase_21 AC 544 ms
103,500 KB
testcase_22 AC 591 ms
103,500 KB
testcase_23 AC 544 ms
103,500 KB
testcase_24 AC 489 ms
103,504 KB
testcase_25 AC 509 ms
103,504 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

MOD = 998244353
r = [0, 1]
e = [2, 1]
for i in range(1, 2 * 10 ** 5 + 1):
    r.append((r[-1] + r[-2]) % MOD)
    e.append((e[-1] + e[-2]) % MOD)

Q = int(input())
for _ in range(Q):
    n = int(input())
    print((5 * r[n] ** 2 - e[n] ** 2) % MOD)

0