Two Pile With Grundy Number

medium
Two players Alice and Bob are playing a game. They have 2 pile's with n1 and n2 coins in it.
They can pick only allowed numbers of coins from any one pile at a time given in an array picks.
Alice goes first and they take alternate turns.
The player who picks the last coin is the winner. Can you find out the winner.

Input Format

The first line contains two integers n1 and n2. Second line contains size of picks array say l picks[0] picks[1] .... picks[l-1]

Output Format

Print the winner (ALICE or BOB).

Constraints

1 <= n1, n2 <= 50

Notice

.

Example

Input
4 3
3
1
4
2
Output
ALICE
Previous
Deleting Divisors
Next
Win Or Freeze

Related Questions