結果
問題 | No.64 XORフィボナッチ数列 |
ユーザー | netyo715 |
提出日時 | 2021-06-28 09:49:15 |
言語 | Python3 (3.12.2 + numpy 1.26.4 + scipy 1.12.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 190 bytes |
コンパイル時間 | 392 ms |
コンパイル使用メモリ | 10,708 KB |
実行使用メモリ | 8,264 KB |
最終ジャッジ日時 | 2023-09-07 18:16:13 |
合計ジャッジ時間 | 1,543 ms |
ジャッジサーバーID (参考情報) |
judge11 / judge15 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 17 ms
7,820 KB |
testcase_01 | AC | 16 ms
8,236 KB |
testcase_02 | AC | 16 ms
7,852 KB |
testcase_03 | AC | 16 ms
8,264 KB |
testcase_04 | AC | 17 ms
8,196 KB |
testcase_05 | AC | 16 ms
7,792 KB |
testcase_06 | WA | - |
testcase_07 | AC | 19 ms
7,836 KB |
testcase_08 | AC | 15 ms
7,852 KB |
testcase_09 | WA | - |
testcase_10 | AC | 16 ms
7,888 KB |
testcase_11 | AC | 16 ms
7,972 KB |
testcase_12 | AC | 16 ms
8,096 KB |
testcase_13 | AC | 15 ms
7,888 KB |
ソースコード
F0, F1, N = map(int, input().split()) if N==0: print(F0) exit() if N==1: print(F1) exit() N %= 3 N -= 1 F = [F0, F1] for i in range(N): F.append(F[-1]^F[-2]) print(F[-1])