結果

問題 No.64 XORフィボナッチ数列
ユーザー mbanmban
提出日時 2016-10-12 18:03:25
言語 C#(csc)
(csc 3.9.0)
結果
AC  
実行時間 26 ms / 5,000 ms
コード長 548 bytes
コンパイル時間 750 ms
コンパイル使用メモリ 115,276 KB
実行使用メモリ 27,528 KB
最終ジャッジ日時 2024-05-01 19:20:04
合計ジャッジ時間 1,607 ms
ジャッジサーバーID
(参考情報)
judge5 / judge4
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 23 ms
27,012 KB
testcase_01 AC 24 ms
25,216 KB
testcase_02 AC 23 ms
22,960 KB
testcase_03 AC 22 ms
26,876 KB
testcase_04 AC 24 ms
25,084 KB
testcase_05 AC 26 ms
25,364 KB
testcase_06 AC 23 ms
27,120 KB
testcase_07 AC 24 ms
25,224 KB
testcase_08 AC 23 ms
25,088 KB
testcase_09 AC 24 ms
25,104 KB
testcase_10 AC 23 ms
25,132 KB
testcase_11 AC 24 ms
25,360 KB
testcase_12 AC 24 ms
27,528 KB
testcase_13 AC 24 ms
27,264 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc)
Copyright (C) Microsoft Corporation. All rights reserved.

ソースコード

diff #

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

class Magatro
{
    static void Main()
    {
        long[] N = Console.ReadLine().Split(' ').Select(s => long.Parse(s)).ToArray();
        if (N[2] % 3 == 0)
        {
            Console.WriteLine(N[0]);
        }
        else if (N[2] % 3 == 1)
        {
            Console.WriteLine(N[1]);
        }
        else
        {
            long ans = N[1] ^ N[0];
            Console.WriteLine(ans);
        }

       

    }

}


0