D - Alice&Brown Editorial /

Time Limit: 2 sec / Memory Limit: 256 MB

配点 : 500

問題文

AliceとBrownはゲームをするのが好きです。今日は以下のゲームを思いつきました。

2つの山があり、はじめにX, Y個の石が置かれています。 AliceとBrownは毎ターン以下の操作を交互に行い、操作を行えなくなったプレイヤーは負けとなります。

  • 片方の山から 2i 個の石を取り、そのうち i 個の石を捨て、残りの i 個の石をもう片方の山に置く。ここで、整数 i (1≦i) の値は山に十分な個数の石がある範囲で自由に選ぶことができる。

Aliceが先手で、二人とも最適にプレイすると仮定したとき、与えられた X, Y に対しどちらのプレイヤーが勝つか求めてください。

制約

  • 0≦ X, Y ≦ 10^{18}

入力

入力は以下の形式で標準入力から与えられる。

X Y

出力

Aliceが勝つときAliceと、Brownが勝つときBrownと出力せよ。


入力例 1

2 1

出力例 1

Brown

Aliceは 2 個石のある山から 2 個取るしかありません。その結果、山の石の数はそれぞれ 0, 2 個となり、Brownは 2 個の石を取り、山の石の数はそれぞれ 1, 0 個となります。 Aliceはこれ以上操作を行うことができないので、Brownの勝ちです。


入力例 2

5 0

出力例 2

Alice

入力例 3

0 0

出力例 3

Brown

入力例 4

4 8

出力例 4

Alice

Score : 500 points

Problem Statement

Alice and Brown loves games. Today, they will play the following game.

In this game, there are two piles initially consisting of X and Y stones, respectively. Alice and Bob alternately perform the following operation, starting from Alice:

  • Take 2i stones from one of the piles. Then, throw away i of them, and put the remaining i in the other pile. Here, the integer i (1≤i) can be freely chosen as long as there is a sufficient number of stones in the pile.

The player who becomes unable to perform the operation, loses the game.

Given X and Y, determine the winner of the game, assuming that both players play optimally.

Constraints

  • 0 ≤ X, Y ≤ 10^{18}

Input

Input is given from Standard Input in the following format:

X Y

Output

Print the winner: either Alice or Brown.


Sample Input 1

2 1

Sample Output 1

Brown

Alice can do nothing but taking two stones from the pile containing two stones. As a result, the piles consist of zero and two stones, respectively. Then, Brown will take the two stones, and the piles will consist of one and zero stones, respectively. Alice will be unable to perform the operation anymore, which means Brown's victory.


Sample Input 2

5 0

Sample Output 2

Alice

Sample Input 3

0 0

Sample Output 3

Brown

Sample Input 4

4 8

Sample Output 4

Alice