結果
問題 |
No.2 素因数ゲーム
|
ユーザー |
|
提出日時 | 2018-07-30 18:21:14 |
言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 477 bytes |
コンパイル時間 | 688 ms |
コンパイル使用メモリ | 64,124 KB |
実行使用メモリ | 6,948 KB |
最終ジャッジ日時 | 2024-09-14 07:14:58 |
合計ジャッジ時間 | 3,734 ms |
ジャッジサーバーID (参考情報) |
judge6 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 13 WA * 18 |
ソースコード
#include <iostream> #include <complex> #include <vector> using namespace std; #define FOR(i,a,b) for(int i=(a); i<(b); i++) #define ll long long int int main(){ ll N; cin >> N; int bitxor = 0; FOR(i, 2, N){ int count = 0; while (N % i == 0){ N /= i; count++; } bitxor ^= count; if (N == 1) break; } if (bitxor) cout << "Alice" << endl; else cout << "Bob" << endl; return 0; }