#C7904. Coin Game Winner

    ID: 51827 Type: Default 1000ms 256MiB

Coin Game Winner

Coin Game Winner

Two players, Alice and Bob, play a coin picking game. Initially, there is a pile containing C coins. On each turn, a player can remove at most K coins from the pile. The players take turns and Alice always goes first. The winning strategy is determined by the following observation: if the number of coins satisfies the condition \(C \mod (K+1) = 0\), then the second player (Bob) can force a win; otherwise, the first player (Alice) wins.

Your task is to determine the winner of the game for each test case provided.

Note: All formulas are represented in \(\LaTeX\) format.

inputFormat

The input begins with an integer (T) representing the number of test cases. Each of the following (T) lines contains two space-separated integers (C) and (K), where (C) is the number of coins and (K) is the maximum number of coins a player can take in one turn.

outputFormat

For each test case, output the name of the winner on a new line. Print "Alice" if the first player wins or "Bob" if the second player wins.## sample

3
4 2
8 3
5 1
Alice

Bob Alice

</p>