結果
問題 |
No.64 XORフィボナッチ数列
|
ユーザー |
|
提出日時 | 2019-04-04 15:53:58 |
言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 1 ms / 5,000 ms |
コード長 | 274 bytes |
コンパイル時間 | 385 ms |
コンパイル使用メモリ | 22,272 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-12-25 23:35:07 |
合計ジャッジ時間 | 1,201 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 11 |
コンパイルメッセージ
main.cpp: In function ‘int main()’: main.cpp:6:10: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 6 | scanf("%lld %lld %lld", &a, &b, &n); | ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ソースコード
#include <stdio.h> int main() { unsigned long long int a, b, n; scanf("%lld %lld %lld", &a, &b, &n); if (n%3 == 0) printf("%lld", a); if (n%3 == 1) printf("%lld", b); if (n%3 == 2) printf("%lld", a^b); return 0; }