Game
题号:NC237297
时间限制:C/C++/Rust/Pascal 1秒,其他语言2秒
空间限制:C/C++/Rust/Pascal 256 M,其他语言512 M
64bit IO Format: %lld

题目描述

Alice and Bob are playing a game.

Initially, there are  () piles of stones, the -th of which has  () stones. We call a pile empty if there are no stones in it currently.

Alice and Bob take turns to operate as follows (of course, Alice operates first):

  1. Arbitrarily pick one pile that is not empty.

  2. Remove some or all stones (at least one) of that pile.

  3. Rearrange the remained stones of that pile. That means, for each remaining stone of that pile, one can move it to another non-empty pile, or just do nothing(then it still remains in the same pile).

The player who can't operate loses, or equally, the player who takes the last stone wins. It can be proved that Alice or Bob has a strategy to win the game. Alice and Bob are wondering who will win the game finally if they both play optimally. So, they give you the entire information about the piles of stones. Please determine who will win the game if they both play optimally.

To make sure you handle their question seriously rather than just guess the right answer, they will ask Q questions, each of which contains l,r, which means that they will play a game on piles in . You should answer all the questions correctly to convince them.

输入描述:

The first line contains two positive integers n, Q ()---the number of piles of stones and the number of games they will play.
The second line contains n positive integers (), denoting that there are a_i stones in the i-th pile initially.
The next Q lines, each of which contains two integers l,r (), denoting they will play a game on piles in .

输出描述:

Output Q lines, each of which contains Alice or Bob, indicating the winner if both sides play optimally.
示例1

输入

复制
2 2
5 4
1 1
2 2

输出

复制
Alice
Alice

说明

In the first case, there is only one pile in each game, then Alice can take all stones from that pile and win the game immediately.
示例2

输入

复制
2 1
100000 100000
1 2

输出

复制
Bob

说明

In the second case, initially, both piles have the same amount of stones. Bob will win as long as he keeps this status until the end of the game.