結果
問題 | No.64 XORフィボナッチ数列 |
ユーザー |
![]() |
提出日時 | 2017-02-20 22:50:30 |
言語 | Java (openjdk 23) |
結果 |
AC
|
実行時間 | 154 ms / 5,000 ms |
コード長 | 438 bytes |
コンパイル時間 | 2,675 ms |
コンパイル使用メモリ | 74,872 KB |
実行使用メモリ | 41,396 KB |
最終ジャッジ日時 | 2024-12-30 11:27:22 |
合計ジャッジ時間 | 5,542 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 11 |
ソースコード
import java.util.Scanner;import java.util.ArrayList;import java.util.Arrays;import java.util.Collections;class Main {public static void main(String[] args) {Scanner in = new Scanner(System.in);long[] f = new long[3];f[0] = in.nextLong();f[1] = in.nextLong();f[2] = f[0] ^ f[1];long n = in.nextLong();System.out.println(f[(int)(n%3)]);in.close();}}