結果
| 問題 | 
                            No.3112 Decrement or Mod Game
                             | 
                    
| コンテスト | |
| ユーザー | 
                             Yu_212
                         | 
                    
| 提出日時 | 2025-04-19 08:50:30 | 
| 言語 | C++23  (gcc 13.3.0 + boost 1.87.0)  | 
                    
| 結果 | 
                             
                                AC
                                 
                             
                            
                         | 
                    
| 実行時間 | 2 ms / 2,000 ms | 
| コード長 | 709 bytes | 
| コンパイル時間 | 3,599 ms | 
| コンパイル使用メモリ | 272,760 KB | 
| 実行使用メモリ | 6,272 KB | 
| 最終ジャッジ日時 | 2025-04-19 08:50:36 | 
| 合計ジャッジ時間 | 5,606 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge1 / judge3 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 3 | 
| other | AC * 65 | 
ソースコード
#include<bits/stdc++.h>
using namespace std;
using ll = long long;
const int iinf = 1e9;
const ll inf = 1e18;
template<typename T>
ostream& operator<<(ostream &o, vector<T> v) {
    for (int i = 0; i < v.size(); i++)
        o << v[i] << (i+1<v.size()?" ":"");
    return o;
}
struct Edge { int to; ll cost; };
int main() {
    cin.tie(0)->sync_with_stdio(false);
    ll A, B;
    cin >> A >> B;
    bool alice_wins;
    if(A == 1){
        alice_wins = true;
    }
    else if(A == 2){
        alice_wins = (B <= 2);
    }
    else {
        if(B <= A-2 || B == A) alice_wins = true;
        else                   alice_wins = false;
    }
    cout << (alice_wins ? "Alice\n" : "Bob\n");
    return 0;
}
            
            
            
        
            
Yu_212