結果
問題 | No.2 素因数ゲーム |
ユーザー |
![]() |
提出日時 | 2015-07-09 17:35:09 |
言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 337 ms / 5,000 ms |
コード長 | 277 bytes |
コンパイル時間 | 1,787 ms |
コンパイル使用メモリ | 157,648 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-12-26 11:35:07 |
合計ジャッジ時間 | 3,576 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 31 |
ソースコード
#include <bits/stdc++.h> using namespace std; int main(){ int n; cin>>n; int ans=0; for(int i=2;i<=n;i++){ if(n%i==0){ int temp=0; while(n%i==0){ temp++; n/=i; } ans^=temp; } } if(ans==0) cout<<"Bob"<<endl; else cout<<"Alice"<<endl; return 0; }