Problem:


Score : 300 points

Problem Statement

A game is played on a strip consisting of N cells consecutively numbered from 1 to N. 

Alice has her token on cell A. Borys has his token on a different cell B.

Players take turns, Alice moves first.
The moving player must shift his or her token from its current cell X to the neighboring cell on the left, cell X-1, or on the right, cell X+1.
Note that it's disallowed to move the token outside the strip or to the cell with the other player's token.
In one turn, the token of the moving player must be shifted exactly once.

The player who can't make a move loses, and the other player wins.

Both players want to win. Who wins if they play optimally?

Constraints

2 \leq N \leq 100

1 \leq A < B \leq N

All input values are integers.

Input

Input is given from Standard Input in the following format:

N A B

Output

Print Alice if Alice wins, Borys if Borys wins, and Draw if nobody wins.

Sample Input 1

5 2 4

Sample Output 1

Alice

Alice can move her token to cell 3. 
After that, Borys will be unable to move his token to cell 3, so he will have to move his token to cell 5. 
Then, Alice moves her token to cell 4. Borys can't make a move and loses. 

Sample Input 2

2 1 2

Sample Output 2

Borys

Alice can't make the very first move and loses.

Sample Input 3

58 23 42

Sample Output 3

Borys



Sample input:
5 2 4


Sample output:
Alice

Submission status: Accepted

Solution code:
n, a, b = map(int, input().split())

# 両端に各コマがあったとして、１．偶数の時　２．奇数の時どちらが勝つ？
# 奇数の時、先に動かすと勝つ
# 偶数の時、先に動かすと負ける
if (b - a) % 2:
  print('Borys')
else:
  print('Alice')

Submission status: Accepted

Solution code:
n,a,b=map(int,input().split());print("Alice"if(b-a)%2==0 else"Borys")

Submission status: Accepted

Solution code:
a,b,c = map(int,input().split())
if (b-c)%2==0:
    print('Alice')
else:
    print('Borys')

Submission status: Accepted

Solution code:
N,A,B=map(int,input().split())
print("ABloircyes"[(B-A)%2::2])

Submission status: Accepted

Solution code:
N,A,B = map(int,input().split())
print("Borys" if (B-A)%2 else "Alice")

Submission status: Accepted

Solution code:
n,a,b=map(int,input().split())
if a==1 and b==2:
  print('Borys')
elif (b-a)%2==0:
  print('Alice')
else:
  print('Borys')

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())

if 0 == (B - A - 1) % 2:
	print("Borys")
else:
	print("Alice")

Submission status: Accepted

Solution code:
N, A, B= map(int, input().split())
if (abs(A-B)-1) % 2 == 1: print('Alice')  
else: print('Borys')

Submission status: Accepted

Solution code:
def main():
    N, A, B = map(int, input().split())
    if (B - A) % 2 == 0:
        print("Alice")
    else:
        print("Borys")


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
a = list(map(int, input().split()))

if (a[2]-a[1])%2 == 0:
    print("Alice")
else:
    print("Borys")

Submission status: Accepted

Solution code:
n,a,b=map(int,input().split())
ans='Borys' if (b-a+1)%2==0 else 'Alice'
print(ans)

Submission status: Accepted

Solution code:
n, a, b = [int(i) for i in input().split()]
k = abs(a-b-1)
if k%2 == 0:
    print("Borys")
else:
    print("Alice")

Submission status: Accepted

Solution code:
# 先に相手の隣に立ったら負け確定
# 一方が距離を縮め、一方が逆方向にいく -> 距離は縮まらない(+-0)
# 両方とも縮める/外側にいく -> 距離は2減る/増える
# 先攻と後攻の間が1 -> 先攻が先に横に立つので負け
# 2 -> 後攻, 3 -> 先攻, .....
n, a, b = map(int, input().split())
dif = max(a, b) - min(a, b)
print("Borys" if dif % 2 == 1 else "Alice")

Submission status: Accepted

Solution code:
n,a,b=map(int,input().split())
between=b-a-1
if between%2==0:
    print('Borys')
else:
    print('Alice')

Submission status: Accepted

Solution code:
import sys
n, a, b = map(int, input().split())
if (b - a) % 2 == 1:
    ans = "Borys"
else:
    ans = "Alice"
print(ans)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
"""
A - Move and Win
https://atcoder.jp/contests/agc020/tasks/agc020_a

"""
import sys


def solve(N, A, B):
    if (A-B)%2:
        return 'Borys'
    return 'Alice'


def main(args):
    N, A, B = map(int, input().split())
    ans = solve(N, A, B)
    print(ans)


if __name__ == '__main__':
    main(sys.argv[1:])

Submission status: Accepted

Solution code:
###template###
import sys
def input(): return sys.stdin.readline().rstrip()
def mi(): return map(int, input().split())
###template###

N,A, B = mi()

if (B-A-1)%2 == 0: print('Borys')
else: print('Alice')

Submission status: Accepted

Solution code:
N,A,B=map(int,input().split())
if (A-B)%2==0:
  print("Alice")
else:
  print("Borys")

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())
if (B + A) % 2 == 1:
    print('Borys')
else:
    print('Alice')

Submission status: Accepted

Solution code:
n,a,b=map(int,input().split())
if (b-a)%2==0:
    print('Alice')
else:
    print('Borys')

Submission status: Accepted

Solution code:
n, a, b = [int(item) for item in input().split()]
if (b - a) % 2 == 0:
    print("Alice")
else:
    print("Borys")

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())

if (B - A) % 2 == 0:
    print('Alice')
else:
    print('Borys')

Submission status: Accepted

Solution code:
n,a,b=map(int,input().split())
ans=['Alice','Borys']
if (b-a)%2==0:
    i=0
else:
    i=1
print(ans[i])

Submission status: Accepted

Solution code:
n, a, b = list(map(int, input().split()))
if (b-a)%2 == 0:
  print('Alice')
elif (b-a)%2 == 1:
  print('Borys')
else:
  print('Draw')

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())
 
if (B - A - 1) % 2 == 0:
  print('Borys')
else:
  print('Alice')

Submission status: Accepted

Solution code:
n,a,b=map(int,input().split())
print("ABloircyes"[(b-a)%2::2])

Submission status: Accepted

Solution code:
n, a, b = map(int, input().split())

if (b - a) % 2 == 0:
    print('Alice')
else:
    print('Borys')

Submission status: Accepted

Solution code:
N, A, B = map(int,input().split())
if (B - A) % 2 == 0:
    print("Alice")
else:
    print("Borys")

Submission status: Accepted

Solution code:
N, A, B = [int(i) for i in input().split()]

print(["Alice", "Borys"][(B - A) % 2])

Submission status: Accepted

Solution code:
N,A,B=map(int,input().split())
print('Alice') if (B-A)%2==0 else print('Borys')

Submission status: Accepted

Solution code:
n, a, b = map(int, input().split())
if (b - a) % 2 == 0:
	print("Alice")
else:
	print("Borys")

Submission status: Accepted

Solution code:
N,A,B = map(int,input().split(" "))
print(['Alice','Borys'][(B-A)%2])

Submission status: Accepted

Solution code:

def main():
    n, a, b = list(map(int, input().split()))

    if (b-a-1)%2 == 0:
        print('Borys')
    else:
        print('Alice')


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())

print("Alice" if (B - A) % 2 == 0 else "Borys")

Submission status: Accepted

Solution code:
n,a,b=map(int,input().split())
print('Borys'if(b-a)%2==1else'Alice')

Submission status: Accepted

Solution code:
n,a,b = map(int, input().split())

if (b-a)%2==1:
    print('Borys')
else:
    print('Alice')

Submission status: Accepted

Solution code:
n, a, b = map(int, input().split())
c = abs(a-b)
if c % 2 == 0:
    ans = "Alice"
else:
    ans = "Borys"
print(ans)

Submission status: Accepted

Solution code:
n, a, b = list(map(int, input().split()))
print("Alice" if (b - a) % 2 == 0 else "Borys")

Submission status: Accepted

Solution code:
n,a,b=map(int,input().split())
if (b - a) % 2 == 0:
  print('Alice')
else:
  print('Borys')

Submission status: Accepted

Solution code:
n,a,b=map(int,input().split())
print("Alice" if (b-a)%2==0 else "Borys")

Submission status: Accepted

Solution code:
N,A,B = map(int, input().split())
D = B - A

if D % 2 == 0:
    print("Alice")
else:
    print("Borys")

Submission status: Accepted

Solution code:
N,A,B = map(int, input().split())

if A % 2 == 0 and B % 2 == 0:
    print("Alice")
elif A % 2 == 0 and B % 2 != 0:
    print("Borys")
elif A % 2 != 0 and B % 2 == 0:
    print("Borys")
elif A % 2 != 0 and B % 2 != 0:
    print("Alice")

Submission status: Accepted

Solution code:
n,a,b=map(int,input().split())
if (b-a-1)%2==0:
  print('Borys')
else:
  print('Alice')

Submission status: Accepted

Solution code:
N,A,B = (int(x) for x in input().split())

if (B-A)%2 == 0:
    print("Alice")
else:
    print("Borys")

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())
while True:
  if abs(B-A)%2 == 1:
    print("Borys")
    break
  elif abs(B-A)%2 == 0:
    print("Alice")
    break

Submission status: Accepted

Solution code:
import sys,collections as cl
Max = sys.maxsize
def l():
	return list(map(int,input().split()))
def m():
	return map(int,input().split())
def s(x):
	a = []
	aa = x[i]
	su = 1
	for i in range(len(x)-1):
		if aa == x[i+1]:
			a.append([aa,su])
			aa = x[i+1]
			su = 1
		else:
			su += 1
	a.append([aa,su])
	return a
def jo(x):
	return " ".join(map(str,x))

n,a,b = m()

k = abs(a-b)
if k == 1:
	print("Borys")
else:
	if k % 2 == 0:
		print("Alice")
	else:
		print("Borys")

Submission status: Accepted

Solution code:
n,a,b = map(int, input().split(" "))

if (b - a) % 2 == 0:
    print("Alice")
else:
    print("Borys")

Submission status: Accepted

Solution code:
N,A,B = list(map(int, input().split()))

if (B-A)%2:
  print('Borys')
else:
  print('Alice')

Submission status: Accepted

Solution code:
n, a, b = list(map(int, input().split()))
if (b - a) % 2:
    print('Borys')
else:
    print('Alice')

Submission status: Accepted

Solution code:
n, a, b = map(int, input().split())
if (a-b) % 2 == 0:
  print('Alice')
else:
  print('Borys')

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())


diff = abs(A - B)
if diff % 2 == 0:
    print('Alice')
else:
    print('Borys')

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split(" "))
if (B - A) % 2 == 0:
    print("Alice")
else:
    print("Borys")

Submission status: Accepted

Solution code:
n,a,b = map(int,input().split())

if abs(a-b) % 2:
  print("Borys")
else:
  print("Alice")

Submission status: Accepted

Solution code:
n,a,b = (int(i) for i in input().split())
if (b-a)%2==0:
    print("Alice")
else:
    print("Borys")

Submission status: Accepted

Solution code:
n,a,b=map(int,input().split())
m=[999]+[0 for i in range(n)]+[999]
m[a]=1
m[b]=2
cnt=0
while 1:
    if cnt%2==0:
        if m[a+1]==0:
            m[a]=0
            m[a+1]=1
            a+=1
        elif m[a-1]==0:
            m[a]=0
            m[a-1]=1
            a-=1
        else:
            print('Borys')
            exit()
    else:
        if m[b-1]==0:
            m[b]=0
            m[b-1]=1
            b-=1
        elif m[b+1]==0:
            m[b]=0
            m[b+1]=1
            b+=1
        else:
            print('Alice')
            exit()

    cnt+=1

Submission status: Accepted

Solution code:
def main():
    N, A, B = list(map(int, input().split()))

    delta = abs(A-B) -1

    if delta%2:
        print("Alice")
    else:
        print("Borys")

main()

Submission status: Accepted

Solution code:
N,A,B = map(int,input().split())
n = B-A-1
if(n%2 == 1): print('Alice')
else: print('Borys')

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline

N, A, B = map(int, input().split())
print("Alice" if (B-A+1)%2 == 1 else "Borys")

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())

if (B - A) % 2 == 0 :
    print('Alice')
else :
    print('Borys')

Submission status: Accepted

Solution code:
n, a, b = map(int, input().split())
print("Borys" if (b-a)%2 else "Alice")

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())
if (A+B) % 2 == 0:
    print('Alice')
else:
    print('Borys')

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())
print(["Alice","Borys"][(B-A)%2!=0])

Submission status: Accepted

Solution code:
N,A,B = map(int, input().split())
if (B-A)%2==0:
    print("Alice")
else:
    print("Borys")

Submission status: Accepted

Solution code:
N,A,B = map(int,input().split())
if (A-B)%2:
  print("Borys")
else:
  print("Alice")

Submission status: Accepted

Solution code:
n, a, b = map(int, input().split())
if n == 2:
    win = 'Borys'
else:
    if abs(a - b) % 2 == 0:
        win = 'Alice'
    else:
        win = 'Borys'

print(win)

Submission status: Accepted

Solution code:
N,A,B=map(int,input().split())
num=abs(A-B)+1
if num%2==1:
    print('Alice')
else:
    print('Borys')

Submission status: Accepted

Solution code:
n,a,b=map(int,input().split())
if((b-a)%2==0):
  print("Alice")
else:
  print("Borys")

Submission status: Accepted

Solution code:
n,a,b=map(int,input().split());print('ABloircyes'[(b-a)%2==1::2])

Submission status: Accepted

Solution code:
n,a,b = map(int,input().split())
print('Alice') if (a-b)%2==0 else print('Borys')

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())
d = abs(A - B) - 1
if d % 2 == 0:
    print("Borys")
else:
    print("Alice")

Submission status: Accepted

Solution code:
n, a, b = map(int, input().split())
aida = b-a-1
if aida%2==0:
  print("Borys")
else:
  print("Alice")

Submission status: Accepted

Solution code:
n,a,b = map(int,input().split())
M = [1]+[0]*n+[1]
a -= 1
b -= 1
M[a] = 1
M[b] = 1
turn = 1
while True:
    if turn == 1:
        if M[a+1] == 1 and M[a-1] == 0:
            M[a-1] = 1
            M[a] = 0
            a -= 1
            turn *= -1
        elif M[a-1] == 1 and M[a+1] == 0:
            M[a+1] = 1
            M[a] = 0
            a += 1
            turn *= -1
        elif M[a-1] == 0 and M[a+1] == 0:
            M[a+1] = 1
            M[a] = 0
            a += 1
            turn *= -1
        else:
            print("Borys")
            exit()
    else:
        if M[b+1] == 1 and M[b-1] == 0:
            M[b-1] = 1
            M[b] = 0
            b -= 1
            turn *= -1
        elif M[b-1] == 1 and M[b+1] == 0:
            M[b+1] = 1
            M[b] = 0
            b += 1
            turn *= -1
        elif M[b-1] == 0 and M[b+1] == 0:
            M[b-1] = 1
            M[b] = 0
            b -= 1
            turn *= -1
        else:
            print("Alice")
            exit()

Submission status: Accepted

Solution code:
N, A, B = list(map(int, input().split()))

if abs(A - B) % 2 == 0:
  print("Alice")
else:
  print("Borys")

Submission status: Accepted

Solution code:
_, A, B = map(int, input().split())
if (A + B) % 2 == 0:
  print('Alice')
else:
  print('Borys')

Submission status: Accepted

Solution code:
N,A,B = map(int,input().split())

sub = B-A-1
ans = ''
if sub%2==0:
    ans = 'Borys'
else:
    ans = 'Alice'
    
print(ans)

Submission status: Accepted

Solution code:
# https://atcoder.jp/contests/agc020/tasks/agc020_a

import itertools
import collections
import bisect
import sys
input = sys.stdin.readline

def main():
    N, A, B = map(int, input().split())

    diff = B - A
    if diff % 2 == 1:
        print("Borys")
    else:
        print("Alice")


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())

if (abs(A - B) + 1) % 2 == 0:
    print('Borys')
else:
    print('Alice')

Submission status: Accepted

Solution code:
n, a, b = map(int, input().split())

if n == 2:
    print("Borys")
elif (b - a) % 2 == 0:
    print("Alice")
elif (b - a) % 2 == 1:
    print("Borys")

Submission status: Accepted

Solution code:
n,a,b=map(int,input().split())

if (b-a)%2==1:
    print("Borys")
else:
    print("Alice")

Submission status: Accepted

Solution code:
n,a,b = map(int,input().split())
if (b-a)%2!=0:
    print("Borys")
else:
    print("Alice")

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())
blocks_between_AB = B-A-1

if blocks_between_AB%2 == 0:
    winner = "Borys"
else:
    winner = "Alice"

print(winner)

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())
dist_AB = B-A-1

if dist_AB%2 == 0:
    winner = "Borys"
else:
    winner = "Alice"

print(winner)

Submission status: Accepted

Solution code:
s=input().split()
if int(s[2])-int(s[1])==1:
    print('Borys')
elif (int(s[2])-int(s[1]))%2==0:
    print('Alice')
else:
    print('Borys')

Submission status: Accepted

Solution code:
a,b,c=map(int,input().split());print("ABloircyes"[(c-b)%2::2])

Submission status: Accepted

Solution code:
N,A,B=map(int,input().split())
print("Alice" if (B-A)%2==0 else "Borys")

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-


def main():
    n, a, b = map(int, input().split())

    if (b - a - 1) % 2 == 1:
        print('Alice')
    else:
        print('Borys')


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
n, a, b = map(int, input().split())

if abs(a-b) % 2 == 0:
  print('Alice')
else:
  print('Borys')

Submission status: Accepted

Solution code:
N,A,B = map(int,input().split())

if A==B :
    if N == 1 :
        ans = "Borys"
    else :
        ans = "Alice"
else :
    if (B-A)% 2 == 0 :
        ans = "Alice"
    else :
        ans = "Borys"
print(ans)

Submission status: Accepted

Solution code:
import sys
stdin = sys.stdin
 
sys.setrecursionlimit(10**6) 
 
def li(): return map(int, stdin.readline().split())
def li_(): return map(lambda x: int(x)-1, stdin.readline().split())
def lf(): return map(float, stdin.readline().split())
def ls(): return stdin.readline().split()
def ns(): return stdin.readline().rstrip()
def lc(): return list(ns())
def ni(): return int(stdin.readline())
def nf(): return float(stdin.readline())

n,a,b = li()

print("Alice" if abs(b-a)%2 == 0 else "Borys")

Submission status: Accepted

Solution code:
N,A,B = map(int,input().split())
d = B-A
print('Borys' if d%2 else 'Alice')

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())
if abs(A - B) % 2 == 0:
    print("Alice")
else:
    print("Borys")

Submission status: Accepted

Solution code:
n, a, b = map(int,input().split())

if((b-a) % 2 == 0):
    print("Alice")
else:
    print("Borys")

Submission status: Accepted

Solution code:
n, a, b = map(int, input().split())
print('Alice') if (b - a) % 2 == 0 else print('Borys')

Submission status: Accepted

Solution code:
N,A,B = map(int,input().split())

if A - N == 0:
    print('Borys')
elif abs(A-B) % 2 == 0:
    print('Alice')
else:
    print('Borys')

Submission status: Accepted

Solution code:
N,A,B = map(int, input().split())
if (B-A-1) % 2:
    print('Alice')
else:
    print('Borys')

Submission status: Accepted

Solution code:
n,a,b = map(int,input().split())

if abs(b-a)%2==1:
  print("Borys")
else:
  print("Alice")

Submission status: Accepted

Solution code:
n,a,b = map(int,input().split())
if (b - a) % 2 == 0:
    print('Alice')
else:
    print('Borys')

Submission status: Accepted

Solution code:
n, a, b = map(int, input().split())
if (b - a - 1) % 2 == 0:
    ans = 'Borys'
else:
    ans = 'Alice'
print(ans)

Submission status: Accepted

Solution code:
n,a,b = (int(i) for i in input().split())
print('Borys' if (b-a)%2 else 'Alice')

Submission status: Accepted

Solution code:
N,A,B = map(int,input().split())

if (B-A)%2 == 0:
    print('Alice')
else:
    print('Borys')

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())
if (B-A)%2 == 0:
    print('Alice')
else:
    print('Borys')

Submission status: Accepted

Solution code:
n, a, b = map(int, input().split())
if (b - a + 1) % 2:
    print("Alice")
else:
    print("Borys")

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())
det = (B-A)%2
if det == 1:
    print('Borys')
else:
    print('Alice')

Submission status: Accepted

Solution code:
n,a,b=map(int,input().split())
if (b-a)%2==1:
  print("Borys")
elif (b-a)%2==0: 
  print("Alice")
else:
  print("Draw")

Submission status: Accepted

Solution code:
n, a, b=map(int,input().split())
print("Alice" if (a - b -1) % 2 else"Borys")

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())

alice = A 
bolice = B
while True:
    if alice + 1 != N + 1 and alice + 1 != bolice:
        alice += 1
    else:
        res = 'Borys'
        break

    if bolice - 1 != 0 and  bolice - 1 != alice:
        bolice -= 1
    else:
        res = 'Alice'
        break

print(res)

Submission status: Accepted

Solution code:
import collections
import itertools
import numpy as np
import sys
def IL(): return list(map(int,input().split()))
def SL(): return input().split()
def I(): return int(sys.stdin.readline())
def S(): return input()

N,A,B = IL()

if (B-A)%2 == 0:
    print("Alice")
else:
    print("Borys")

Submission status: Accepted

Solution code:
N, A, B = map(int, raw_input().split())
print "Alice" if (B-A)%2 == 0 else "Borys"

Submission status: Accepted

Solution code:
n,a,b =list(map(int,input().split()))
if(abs(a-b-1)%2==0):
  print("Borys")
elif(abs(a-b-1)%2==1):
  print("Alice")
else:
  print("Draw")

Submission status: Accepted

Solution code:
N,A,B = [int(i) for i in input().split()]

if abs(B-A)%2 != 0:
    print('Borys')
else:
    print('Alice')

Submission status: Accepted

Solution code:
n,a,b = map(int, input().split())
print('Alice' if (a-b) % 2 ==0 else 'Borys')

Submission status: Accepted

Solution code:
n, a, b = map(int, input().split())

if n == 2:
    print("Borys")
elif (b-a-1)%2 == 0:
    print("Borys")
else:
    print("Alice")

Submission status: Accepted

Solution code:
n,a,b = map(int,input().split())
c = b-a-1
if c % 2 == 0:
    print('Borys')
else:
    print('Alice')

Submission status: Accepted

Solution code:
import sys
from collections import deque
import copy
import math
def get_read_func(fileobject):
    if fileobject == None :
        return raw_input
    else:
        return fileobject.readline

def main():
    if len(sys.argv) > 1:
        f = open(sys.argv[1])
    else:
        f = None
    read_func = get_read_func(f);
    input_raw = read_func().strip().split()
    [N, A, B] = [int(input_raw[0]), int(input_raw[1]), int(input_raw[2])]
    if (B- A - 1) % 2 == 1:
        print "Alice"
    else:
        print "Borys"


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
n,a,b=map(int,input().split())
print('Borys' if (b-a)%2 else 'Alice')

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split(" "))

print(["Alice", "Borys"][(B-A)%2])

Submission status: Accepted

Solution code:
n, a, b = map(int, input().split())

if (b - a) % 2 == 0:
  ans = 'Alice'
else:
  ans = 'Borys'
print(ans)

Submission status: Accepted

Solution code:
def solve(N, A, B):
    d1 = A - 1
    d2 = B - A - 1
    d3 = N - B

    if d2 % 2 == 1:
        return "Alice"
    else:
        return "Borys"
        # if d1 == 0 and d2 == 0:
        # if d1 % 2 == 0 and d3 % 2 == 0:
        #     return "Borys"
        # else:
        #     return "Draw"


if __name__ == "__main__":
    N, A, B = tuple(map(int, input().split(" ")))
    print(solve(N, A, B))

Submission status: Accepted

Solution code:
import time
n, a, b = map(int, input().split())
index=0
flag=1
start = time.time()
while True:
    if a == 1 and b == a+1 and index % 2 == 0:
        print("Borys")
        break
    elif b == n and b == a+1 and index % 2 == 1:
        print("Alice")
        break
    if b == a+1:
        flag=0
    else:
        flag=1
    if flag:
        if index%2==0:
            a+=1
        else:
            b-=1
    else:
        if index%2==0:
            a-=1
        else:
            b+=1
    index+=1
    if time.time()-start > 1:
        print("Draw")
        break

Submission status: Accepted

Solution code:
a,b,c = map(int,input().split(" "))
if (c - b) % 2 == 0:
  print("Alice")
else:
  print("Borys")

Submission status: Accepted

Solution code:
n, a, b = map(int, input().split())
print('Borys' if ((b - a) % 2) else 'Alice')

Submission status: Accepted

Solution code:
import sys
n, a, b = map(int, input().split())
turn = 'Al'
while(True):
  if (turn == 'Al'): #Alice's Turn
    if ((a == 1) & (b == 2)):
      print('Borys')
      sys.exit()
    elif (b - a == 1):
      a -= 1
    else:
      a += 1
    turn = 'Bo'
  else:
    if ((a == n - 1) & (b == n)):
      print('Alice')
      sys.exit()
    elif (b - a == 1):
      b += 1
    else:
      b -= 1
    turn = 'Al'

Submission status: Accepted

Solution code:
n, a, b = map(int, input().split())
if ((a - b) % 2 == 0):
  print("Alice")
else:
  print("Borys")

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())

if (abs(B-A)-1) % 2 == 1:
    print("Alice")
else:
    print("Borys")

Submission status: Accepted

Solution code:
n, a, b = list(map(int, input().split()))

ans = 'Borys' if (b - a) % 2 else 'Alice'

print(ans)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

import sys, re
from collections import deque, defaultdict, Counter
from math import sqrt, hypot, factorial, pi, sin, cos, radians
if sys.version_info.minor >= 5: from math import gcd
else: from fractions import gcd 
from heapq import heappop, heappush, heapify, heappushpop
from bisect import bisect_left, bisect_right
from itertools import permutations, combinations, product
from operator import itemgetter, mul
from copy import deepcopy
from functools import reduce, partial
from fractions import Fraction
from string import ascii_lowercase, ascii_uppercase, digits

def input(): return sys.stdin.readline().strip()
def ceil(a, b=1): return int(-(-a // b))
def round(x): return int((x*2+1) // 2)
def fermat(x, y, MOD): return x * pow(y, MOD-2, MOD) % MOD
def lcm(x, y): return (x * y) // gcd(x, y)
def lcm_list(nums): return reduce(lcm, nums, initial=1)
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
MOD = 10 ** 9 + 7

N, A, B = MAP()

if abs(A - B) % 2 == 0:
    print('Alice')
else:
    print('Borys')

Submission status: Accepted

Solution code:
n, a, b = list(map(int,input().split()))
if (b-a+1)%2:
    print("Alice")
else:
    print("Borys")

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split(" "))
distance = abs(A-B) - 1

if distance % 2 == 0:
    print("Borys")
else:
    print("Alice")

Submission status: Accepted

Solution code:
n, a, b = map(int, input().split())
if (b - a) % 2 == 0:
    print('Alice')
else:
    print('Borys')

Submission status: Accepted

Solution code:
n,a,b=map(int,input().split())

if((b-a)%2==1):
    print("Borys")
else:
    print("Alice")

Submission status: Accepted

Solution code:
n,a,b = (int(i) for i in input().split())
if (b-a)%2 == 0:
  print('Alice')
else:
  print('Borys')

Submission status: Accepted

Solution code:
a,b,c=map(int,input().split())
print("Alice"if abs(b-c)%2!=1else"Borys")

Submission status: Accepted

Solution code:
N,a,b=map(int, input().split())
if (b-a)%2!=0:
    print("Borys")
else:
    print("Alice")

Submission status: Accepted

Solution code:
def inpl(): return list(map(int, input().split()))
m, a, b = inpl()
print(['Alice','Borys'][(a+b)%2])

Submission status: Accepted

Solution code:
N,A,B = map(int,input().split())
print('Alice' if (B-A)%2 == 0 else 'Borys')

Submission status: Accepted

Solution code:
N, A, B=map(int,input().split())
print("Borys" if (B-A)%2 else "Alice" )

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())

print('Borys' if (B - A + 1) % 2 == 0 else 'Alice')

Submission status: Accepted

Solution code:
N, A, B = list(map(int, input().split()))
if (B-A)%2==0:
    print('Alice')
else:
    print('Borys')

Submission status: Accepted

Solution code:
N,A,B = map(int,input().split(' '))

k = abs(A-B)

if k % 2 == 0:
	print("Alice")
else:
	print("Borys")

Submission status: Accepted

Solution code:
N,A,B=map(int,input().split())
while True:
  if B!=A+1:
    A+=1
  else:
    if A==1:
      print("Borys")
      exit()
    else:
      A-=1
 
  if A!=B-1:
    B-=1
  else:
    if B==N:
      print("Alice")
      exit()
    else:
      B+=1

Submission status: Accepted

Solution code:
N,A,B = map(int,input().split())

if (B-A)%2 == 0:
    print("Alice")
else:
    print("Borys")

Submission status: Accepted

Solution code:
n, a, b = map(int,input().split())
if (b-a)%2 == 0:
    print('Alice')
else:
    print('Borys')

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())
if (B - A) % 2:
    print("Borys")
else:
    print("Alice")

Submission status: Accepted

Solution code:
if __name__ == '__main__':
    N, A, B = map(int, input().split())
    
    if A%2 == B%2:
        print("Alice")
    else:
        print('Borys')

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())

if (B - A - 1) % 2:
    print('Alice')
else:
    print('Borys')

Submission status: Accepted

Solution code:
n,a,b = map(int, input().split())
c = b-a
if c % 2 == 0:
  print("Alice")
elif c % 2 == 1:
  print("Borys")

Submission status: Accepted

Solution code:
n,a,b=map(int,input().split())
bet=abs(b-a)
if bet%2==0:
  winner='Alice'
else:
    winner='Borys'
    
print(winner)

Submission status: Accepted

Solution code:
N, A, B = [int(_) for _ in input().split()]
if (B - A) % 2:
    print('Borys')
else:
    print('Alice')

Submission status: Accepted

Solution code:
n, a, b = [int(i) for i in input().split()]

# 勝ち負けが決まるのはAB######か#######ABのようになる時
# 勝負はAとBの距離、そして背後の余白マスのみに依存
# どっちに動こうが関係ない
if (a - b) % 2 == 0:
    print("Alice")
else:
    print("Borys")

Submission status: Accepted

Solution code:
N,A,B = map(int,input().split())
spc = B -A -1
if spc%2 == 1:
    print("Alice")
else:
    print("Borys")

Submission status: Accepted

Solution code:
n,a,b=map(int,input().split())
print("Borys" if (a-b)%2 else "Alice")

Submission status: Accepted

Solution code:
import sys


def next_str() -> str:
    result = ""
    while True:
        tmp = sys.stdin.read(1)
        if tmp.strip() != "":
            result += tmp
        elif tmp != '\r':
            break
    return result


def next_int() -> int:
    return int(next_str())


def main() -> None:
    n, a, b = [next_int() for _ in range(3)]

    if (b - a) % 2 == 0:
        print("Alice")
    else:
        print("Borys")


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
def inpl(): return [int(i) for i in input().split()]

N, A, B = inpl()
if (A-B)%2:
    print('Borys')
else:
    print('Alice')

Submission status: Accepted

Solution code:
_,a,b=map(int,input().split())
print(['Alice','Borys'][abs(b-a)%2==1])

Submission status: Accepted

Solution code:
n,a,b=map(int,input().split())
if n==2:
    print("Borys")
elif (b-a-1)%2==0:
    print("Borys")
else:
    print("Alice")

Submission status: Accepted

Solution code:
N,A,B = map(int,input().split())
if (B - A - 1) % 2 == 0:
    ans = "Borys"
else:
    ans = "Alice"  
print(ans)

Submission status: Accepted

Solution code:

N,A,B=map(int, input().split())

if (B-A) % 2 == 0:
    print("Alice")
else:
    print("Borys")

Submission status: Accepted

Solution code:
N,A,B = list(map(int,input().split()))
if (B - A) % 2 == 0:
    print("Alice")
else :
    print("Borys")

Submission status: Accepted

Solution code:
N,A,B=map(int,input().split())
if (B-A)%2==0:
  print('Alice')
else:
  print('Borys')

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())
x = B-A
if x%2 == 0:
    print("Alice")
else:
    print("Borys")

Submission status: Accepted

Solution code:
N, A, B = list(map(int, input().strip().split()))
if (B - A) % 2 == 0:
	print("Alice")
else:
	print("Borys")

Submission status: Accepted

Solution code:
N, A, B = map(int, input().split())
print("Alice" if (B-A)%2 == 0 else "Borys")