結果
| 問題 | No.64 XORフィボナッチ数列 |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2018-06-05 19:57:47 |
| 言語 | C++11(廃止可能性あり) (gcc 15.2.0 + boost 1.89.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 5,000 ms |
| コード長 | 366 bytes |
| 記録 | |
| コンパイル時間 | 1,274 ms |
| コンパイル使用メモリ | 158,556 KB |
| 実行使用メモリ | 6,944 KB |
| 最終ジャッジ日時 | 2024-06-30 10:04:52 |
| 合計ジャッジ時間 | 1,880 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 11 |
ソースコード
#include<bits/stdc++.h>
using namespace std;
typedef pair<int, int> pii;
typedef long long int ll;
int main() {
cin.tie(0);
ios::sync_with_stdio(false);
ll a, b, c, n;
cin >> a >> b >> n;
if (n % 3 == 0)
cout << a << endl;
else if (n % 3 == 1)
cout << b << endl;
else if (n %3 == 2)
cout << (a^b) << endl;
}