結果

問題 No.64 XORフィボナッチ数列
ユーザー キョウチクキョウチク
提出日時 2022-05-17 18:41:04
言語 Java21
(openjdk 21)
結果
AC  
実行時間 127 ms / 5,000 ms
コード長 401 bytes
コンパイル時間 4,861 ms
コンパイル使用メモリ 72,244 KB
実行使用メモリ 55,956 KB
最終ジャッジ日時 2023-10-13 17:43:33
合計ジャッジ時間 7,775 ms
ジャッジサーバーID
(参考情報)
judge14 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 127 ms
55,916 KB
testcase_01 AC 127 ms
55,696 KB
testcase_02 AC 126 ms
55,912 KB
testcase_03 AC 125 ms
55,760 KB
testcase_04 AC 121 ms
55,684 KB
testcase_05 AC 126 ms
55,816 KB
testcase_06 AC 124 ms
55,600 KB
testcase_07 AC 127 ms
55,728 KB
testcase_08 AC 126 ms
55,816 KB
testcase_09 AC 126 ms
55,956 KB
testcase_10 AC 126 ms
55,688 KB
testcase_11 AC 124 ms
55,620 KB
testcase_12 AC 127 ms
55,680 KB
testcase_13 AC 126 ms
55,820 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;
public class Test11 {
  public static void main(String[] args){
    Scanner sc=new Scanner(System.in);
    String[] line;
    line=sc.nextLine().split(" ");
    long[] f=new long[3];
    f[0]=Long.parseLong(line[0]);
    f[1]=Long.parseLong(line[1]);
    f[2]=f[0]^f[1];
    long n=Long.parseLong(line[2]);
    int k=(int)(n%3);
    System.out.println(f[k]);
    sc.close();
  }
}
0