【BZOJ 2463】 谁能赢呢?

【题目链接】

            https://www.lydsy.com/JudgeOnline/problem.php?id=2463

【算法】

             n为偶数时必胜,否则必败

【代码】

          

#include<bits/stdc++.h>
using namespace std;

int n;

int main() 
{
        
        while (scanf("%d",&n) && n)
        {
                if (n & 1) printf("Bob
");
                else printf("Alice
");
        }
        
        return 0;
    
}
原文地址:https://www.cnblogs.com/evenbao/p/9298948.html