Problem:


Score : 200 points

Problem Statement

There are some animals in a garden. Each of them is a crane with two legs or a turtle with four legs.

Takahashi says: "there are X animals in total in the garden, and they have Y legs in total." Determine whether there is a combination of numbers of cranes and turtles in which this statement is correct.

Constraints

1 \leq X \leq 100

1 \leq Y \leq 100

All values in input are integers.

Input

Input is given from Standard Input in the following format:

X Y

Output

If there is a combination of numbers of cranes and turtles in which the statement is correct, print Yes; otherwise, print No.

Sample Input 1

3 8

Sample Output 1

Yes

The statement "there are 3 animals in total in the garden, and they have 8 legs in total" is correct if there are two cranes and one turtle. Thus, there is a combination of numbers of cranes and turtles in which the statement is correct.

Sample Input 2

2 100

Sample Output 2

No

There is no combination of numbers of cranes and turtles in which this statement is correct.

Sample Input 3

1 2

Sample Output 3

Yes

We also consider the case in which there are only cranes or only turtles.



Sample input:
3 8


Sample output:
Yes

Submission status: Wrong Answer

Solution code:
import itertools
x, y = map(int, input().split())
num = [i for i in range(1, x + 1)]
comb = list(itertools.combinations(num, 2))
print(num)
if y % 4 == 0 and y // 4 == x:
    print("Yes")
    exit()
elif y % 2 == 0 and y // 2 == x:
    print("Yes")
    exit()
for j in comb:
    print(j)
    if j[0] * 4 + j[1] * 2 == y:
        print("Yes")
        exit()
print("No")

Submission status: Wrong Answer

Solution code:
X,Y = map(int,input().split())
isOK = False
kame = 0
turu = int(Y/2)
if turu == X:
  isOK = True
for i in range(turu-X):
  if turu != X:
    kame = kame + 1
    turu = turu - 2
  if (turu+kame) == X:
    isOK = True
    break
if Y%2 == 1:
  isOK=False
if isOK == True:
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
number = input()
list = number.split()


def hoge(a, b):
    if b % 3 == 0 or a * 4 < b:
        print("No")
        return
    else:
        for i in range(a):
            n = i + 1
            n2 = a - n
            if n * 2 + n2 * 4 == b:
                print("Yes")
                return
        else:
            print("No")


hoge(int(list[0]), int(list[1]))

Submission status: Wrong Answer

Solution code:
X, Y = map(int, input().split())

t = (Y - 2 * X) / 2
c = (4 * X - Y) / 2

if c < 0 or t < 0:
    print('No')
else:
    if int(c+t) == X:
        print('Yes')
    else:
        print('No')

Submission status: Wrong Answer

Solution code:
x = list(map(int, input().split()))
def func(x):
    for i in range(101):
        for j in range(101):
            if i+j>x[0]:
                break
            if i*2 + j*4 == x[1]:
                print('Yes')
                return
    print('No')
    return
func(x)

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())
count = 0

for k in range(26):
    kame = k
    turu = x-k
    ashi = 2*turu + 4*kame
    if ashi==y:
        count += 1
        break

if count>0:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
X, Y = map(int, input().split())
if (Y == 2*X) | (Y == 2*X+2) | (Y == 2*X+4) | (Y == 2*X+6) | (Y == 4*X):
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())

if y % 2 == 1 or x > 50:
    answer = 'No'

if y >= x*2 and y <= x*4:
    answer = 'Yes'
else:
    answer = 'No'
    

    
print(answer)

Submission status: Wrong Answer

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

a = (X*4 - Y) / 2 
b = X - a 

if a + b == X and (2*a + 4*b) ==Y:
  if a>=0 and b>=0:
    print('Yes')
  elif Y == 2*X:
    print('Yes')
  elif Y == 4*X:
    print('Yes')
  else:
    print('No')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
x,y = map(int,input().split())
crain = (4 * x - y) / 2
if crain.is_integer() and crain > 0:
    crain = int(crain)
    print('Yes')
else:
    print('No')

Submission status: Wrong Answer

Solution code:
import sys

X, Y = map(int, input().split(" "))

for t in range(X + 1):
    for c in range(X + 1):
        if X < t + c:
            print("No")
            sys.exit()
            
        if Y == ((t * 4) + (c * 2)):
            print("Yes")
            sys.exit()

print("No")

Submission status: Wrong Answer

Solution code:
X, Y = map(int, input().split())
b = 0
is_ok = False
while 4*X - Y - 2*b >= 0:
	if 4*X - Y - 2*b == 0:
		is_ok = True
		break
	b += 1

if is_ok:
	print("Yes")
else:
	print("No")

Submission status: Wrong Answer

Solution code:
x,y=map(int,input().split())
if y<x or y&1:
	print('No')
elif x*2==y:
	print('Yes')
elif x*4==y:
	print('Yes')
else:
	c=y//2
	f=0
	y=y//4
	while True:
		if c==x:
			print('Yes')
			f=1
			break
		if c>y:
			c-=1
		else:
			break
	if not f:
		print('No')

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())

no_flag = 0

if y - (4 * x) == 0:
    print("Yes")
elif y - (2 * x) == 0:
    print("Yes")
else:
    for cnt in range(x):
        if y >= 4 and y % (2*(x-(cnt))) != 0:
            y -= 4
        elif y >= 2:
            y -= 2

        if y == 0 and cnt == x-1:
            no_flag = 0
        else:
            no_flag = 1

    if no_flag == 0:
        print("Yes")
    elif no_flag == 1:
        print("No")

Submission status: Wrong Answer

Solution code:
#!/usr/bin/env python3
import sys
import numpy as np

YES = "Yes"  # type: str
NO = "No"  # type: str


def solve(X: int, Y: int):
    a = (4*X-Y)/2
    if a.is_integer and a>=0:
        print(YES)
    else:

        print(NO)

    return


# Generated by 1.1.7.1 https://github.com/kyuridenamida/atcoder-tools  (tips: You use the default template now. You can remove this line by using your custom template)
def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    X = int(next(tokens))  # type: int
    Y = int(next(tokens))  # type: int
    solve(X, Y)

if __name__ == '__main__':
    main()

Submission status: Wrong Answer

Solution code:
X, Y = map(int, input().split())

crain = (4*X - Y) / 2
tu = X - crain
if crain.is_integer() and crain >= 0:
    print("Yes")
elif tu.is_integer() and tu >=0:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())
f = False
for i in range(x+1):
    for j in range(x+1):
        if (y == (i*2 * j*4)):
            if (x == i + j):
                f = True
                break;
if f:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
x,y = map(int, input().split())

if y//2 >= x >= y//4:
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
x,y = map(int,input().split())
crain = (4 * x - y) / 2
if crain.is_integer() and crain >= 0:
    crain = int(crain)
    print('Yes')
else:
    print('No')

Submission status: Wrong Answer

Solution code:
X, Y = map(int, input().split())

bird_only = 2 * X
r = (Y-bird_only) / 2
if r <= X:
    print('Yes')
else:
    print('No')

Submission status: Wrong Answer

Solution code:
X,Y = map(int, input().split())
ans = 0
 
#つるをi
 
for i in range(X):
  if 2*i ==  4*X - Y:
      ans +=1
  elif 2*i == Y:
      ans +=1
  elif 4*(X-i) == Y:
      ans +=1
 
if ans > 0:
  print('Yes') 
else:
  print('No')

Submission status: Wrong Answer

Solution code:
x, y = map(int,input().split())
z = -2
if x != 0:
    for i in range(x):
        if i % 2 == 0:
            z +=4
        else:
            z +=2
    if z == y:
        print("Yes")
    else:
        print("No")
elif x == 0 and y == 0:
    print("Yes")

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())
count = 0

for k in range(25):
    kame = k
    turu = x-k
    ashi = 2*turu + 4*kame
    if ashi==y:
        count += 1
        break

if count>0:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
a = input().split()
# 奇数の時
if int(a[1]) % 2 != 0:
    print('No')
elif int(a[0]) * 4 == int(a[1]) or int(a[0]) * 2 == int(a[1]):
    print('Yes')
elif 2 * int(a[0]) >= int(a[1]) and 2 * int(a[0]) - int(a[1]) / 2 >= 1:
    print('Yes')
else:
    print('No')

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())
aa =  y - 2 * x
a = aa / 2
b = x - a
print("Yes" if 0 <= a <= x and 0 <= b <= x and a + b == x and 4 * a + 2 * b == 7else 'No')

Submission status: Wrong Answer

Solution code:
n,m=(int(x) for x in input().split())
if (4*n-m)%2==0 and 4*n-m>=2 and 2*n-(4*n-m)>=2:
    print('Yes')
else :
    print('No')

Submission status: Wrong Answer

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

for i in range(b):
  if b*2 == t:
    print("Yes")
    break
  elif b*4 == t:
    print("Yes")
    break
  elif b*6 ==t:
    print("Yes")
    break
  else:
    print("No")
    break

Submission status: Wrong Answer

Solution code:
def resolve():
	# N: number of Tsuru
	# Y = 2N + 4(X-N) = 4X -2N
	# print 'Yes' if int N exists for given equation or 'No'.
	# X: total animals, Y: total legs
	X, Y = map(int, input().split())
	K = (4 * X) - Y
	if Y % 2 != 0:
		print('No')
	elif 0 < K < 50:
		print('Yes')
	else:
		print('No')
resolve()

Submission status: Wrong Answer

Solution code:
# Xは動物の総数,Yは動物の足の総数
X,Y = map(int, input().split())

# 亀は4本の足を持ち，鶴は2本の足を持つ．
kame = 4
turu = 2

# まずは鶴が1匹の時だけを判定,奇数は有えないので排除
if Y == 2 and X == 1:
  print("Yes")
elif Y == 100 and X*kame < Y:
  print("No")
elif Y % turu != 0:
  print("No")
elif X*2 < Y:
  print("No")
else:
  ans = Y
  while True:
    Y = Y % 2
    ans = ans/2
    if Y != 0:
      print("No")
      break
    elif Y == 0 and ans == 0:
      print("Yes")
      break

Submission status: Wrong Answer

Solution code:
X,Y = map(int,input().split())
Z= 0
A= 0
for i in range(X-1):
    if i/2==0:
        Z+4
    elif i/2==1:
        (Z+2)
if Z+4+(Z+2)*2==Y:
    print("Yes")
elif Z+2==Y:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
if __name__ == "__main__":
    x, y = map(int, input().split())

    a = (4*x-y)/2
    b = (y-2*x)/2

    if a >= 0 and b >=0:
        print("Yes")
    else:
        print("No")

Submission status: Wrong Answer

Solution code:
n,m = map(int,input().split())
num_c = (4*n - m)/2
if 0 <= num_c <= n:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
x,y= map(int, input().split())
if y %2 == 0:
    if x*4 >=  y >= x*2:
      for i in range(x):
        if (x*4*i) - ((x-i)*2) == y:
            print("YES")
            break
      else:
        print("NO")
    else:
        print("NO")
else:
      print("NO")

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())

for i in range(0, x + 1):
  for j in range(0, x + 1):
    if (i + j == x) and (2 * i + 4 * j == y):
      print('Yes')
    else:
      print('No')

Submission status: Wrong Answer

Solution code:
x = list(map(int, input().split()))
def func(x):
    for i in range(101):
        for j in range(101):
            if i*2 + j*4 == x[1]:
                print('Yes')
                return
    print('No')
    return
func(x)

Submission status: Wrong Answer

Solution code:
x,y=list(map(int,input().split()))
sum=0
if x==1:
    if y==2 or y==4:
        print("Yes")
    else:
        print("No")
elif y%2!=0:
    print("No")
else:
    for i in range(x):
        #print(i)
        if sum%4==2 and sum!=y:
            sum+=2
            #print(sum)
        elif sum%4==0 and sum!=y:
            sum+=4
            #print(sum)
    if sum==y:
        print("Yes")
    else:
        print("No")

Submission status: Wrong Answer

Solution code:
def main():
    x,y=map(int,input().split())
    if x*2==y or x*4==y:#すべて鶴か亀と想定
        print("Yes")
    else:
        turu=x*2
        kame=(y-turu)/2
        turu=x-kame
        if kame+turu==x and turu>0:
            print("Yes")
        else:
            print("No")
if __name__ == "__main__":
    main()

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())

b = y - 2 * x
a = x - b

ans = "Yes" if (a >= 0 and b >= 0) else "No"
if a == 0 and b == 0:
    ans = "No"
print(ans)

Submission status: Wrong Answer

Solution code:
X, Y = map(int, input().split())
if 4 * X >= Y and Y % 4 == 2 or Y % 4 == 0:
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

Solution code:
xy = list(map(int, input().split()))
 
if 4*xy[0]-xy[1]<=0 or -2*xy[0]+xy[1]<=0:
    print('No')
else:
    print('Yes')

Submission status: Wrong Answer

Solution code:
X, Y = map(int, input().split())

if Y/4 <= X and (Y%X ==0 or Y%X ==2):
  print("Yes")
  exit()
else:
  print("No")
  exit()

print("No")

Submission status: Wrong Answer

Solution code:
import sys
X,Y = map(int,input().split())
y = Y / 2
if Y % 2 != 0:
    print("No")
    sys.exit()

for i in range(0,X + 1):
    for j in range(0,X + 1):
        if Y == 2 * i + 4 * j:
            print("Yes")
            sys.exit()
print("No")

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())

a = (4 * x - y) // 2
b = (y - 2 * x) // 2
if 0 <= a and 0 <= b and (2 * a + 4 * b) <= 100:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
z=[]
x, y= map(int,input().split())
for i in range(x):
    if (4*i)+(2*(x-i))==y:
        z.append('1')
        

if len(z)>0:
    print('YES')

if len(z)<=0:
    print('NO')

Submission status: Wrong Answer

Solution code:
n=input()
x,y=n.split()
z=(4*int(x)-int(y))/2
if z.is_integer and 100>=z>=0:
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
x,y = map(int, input().split())

crain = (4*x-y)/2
tar = -1*(2*x-y)/2

if (crain.is_integer() and crain > 0) or (tar.is_integer() and tar > 0):
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
X,Y = map(int,input().split())

a = Y/2
b = 2*X
c = Y*2
if c>=b>=a and Y%2==0:
    print('Yes')
else:
    print('No')

Submission status: Wrong Answer

Solution code:
X, Y = map(int, input().split())

for i in range(1, X+1):
    for j in range(1, X+1):
        if Y == i * 2 + j * 4:
            print('Yes')
            exit()

if Y == X * 2 or Y == X * 4:
    print('Yes')
else:
    print('No')

Submission status: Wrong Answer

Solution code:
x,y=map(int, input().split())
a=False

for i in range(0,x+1):
  print(i, x-i)
  if i*2+(x-i)*4==y:
    a=True
    break
    
if a==True:
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

Solution code:
x,y = list(map(int, input().split()))
if y > 4*x:
  print("No")
else:
  if y % 2 == 0 and y > x*2:
    print("Yes")
  else:
    print("No")

Submission status: Wrong Answer

Solution code:
x,y = map(int, input().split())

if (4*x - y)  / 2 >= 0:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
X,Y = map(int, input().split())

for i in range(1,X+1):
    foot = 2*i+4*(X-i)
    if foot==Y:
        print('Yes')
        break
else:
    print('No')

Submission status: Wrong Answer

Solution code:
X,Y = map(int, input().split())

for kame in range(1,X):
    if (2*(X-kame)+4*kame)==Y:
        print("Yes")
        break
else:
    print("No")

Submission status: Wrong Answer

Solution code:
X, Y = map(int, input().split())

t = (Y - 2 * X) / 2
c = (4 * X - Y) / 2

if c < 0 or t < 0:
    print('No')
else:
    if c+t == X:
        print('Yes')
    else:
        print('No')

Submission status: Wrong Answer

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

if N > 50:
  N = 50
  
for i in range(1, N+1):
    # 足の数
    f = 2 * i + 4 * (N - i)
    if f == M:
        print('Yes')
        break
else:
    print('No')

Submission status: Wrong Answer

Solution code:
X, Y = map(int, input().split())

x = (4*X - Y)/2
y = X - x

if x >= 0 and x.is_integer():
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

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

if a[1]%2==1:
	print("No")

else:
	if 4*a[0]<a[1]:
		print("No")

	else:
		print("Yes")

Submission status: Wrong Answer

Solution code:
x,y=map(int, input().split())


crain = (4 * x - y) / 2
if crain.is_integer() and crain > 0:
    crain = int(crain)
    print('Yes')
elif crain == 0:
    print('Yes')
else:
    print('No')

Submission status: Wrong Answer

Solution code:
import numpy
X,Y=map(int,input().split())

if Y%2 != 0:
    print("No")

else:
    N_max = int(Y/2)
    for n in numpy.array(range(N_max, -1, -2)):
        if X == n + (N_max - n)/2:
            print("Yes")
            break
        else:
            if n == 0:
                print("No")

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())

for i in range(50):

    for j in range(50):
        if (i * 2) + (j * 4) == y and i + j == x:
            print('Yes')
            exit()
print('No')

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())

if y % 2 == 1:
    answer = 'No'

if y >= x*2 and y <= x*4:
    answer = 'Yes'
else:
    answer = 'No'
    
print(answer)

Submission status: Wrong Answer

Solution code:
X, Y = map(int, input().split())

if 4 * X <= Y:
  print("No")
elif Y / 2 <= X:
  print("No")
else:
  y = abs(Y - 2 * X)
  x = abs(4 * X - Y)
  if y%2 == 0 and x%2 == 0:
    print("Yes")
  else:
    print("No")

Submission status: Wrong Answer

Solution code:
x, y = map(int,input().split())
z = -2
if x != 0:
    for i in range(x):
        if i % 2 == 0:
            z +=4
        else:
            z +=2
    if z == y:
        print("Yes")
    else:
        print("No")
if x == 0 and y == 0:
    print("Yes")

Submission status: Wrong Answer

Solution code:
c = input()
c = c.split(' ')
x = int(c[0])
y = int(c[1])
sa = y - 2 * x
if sa % 4 == 0:
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
X,Y = map(int,input().split())
if 2*X == Y or 4*X == Y or Y%X ==1 or Y%X == 2:
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
s = [input() for i in range(1)] 
li = list(map(int, s[0].split()))
li1 = li[0]
li2 = li[1]
y = ((li2 /2 - li1) * 10)%10
if y == 0:
    if li1 - (li2 /2 - li1) >= 0:
        print("Yes")
    if li1 - (li2/2 - li1) < 0:
        print("No")
if y != 0:
    print("No")

Submission status: Wrong Answer

Solution code:
import os

def main():
  args = list(map(int, input().split()))
  nb = args[0]
  nl = args[1]
  if nl / (nb * 4) > nb:
    print('NO')
    return
  if (nl % (nb * 2)) % 2 == 0:
    print('YES')
  else:
    print('NO')

if __name__ == '__main__':
  main()

Submission status: Wrong Answer

Solution code:
X,Y = map(int, input().split())
ans = 0

#つるをi

for i in range(X):
  if 2*i ==  4*X - Y:
      ans +=1
  elif 4*i == Y:
      ans +=1
  elif 2*(X-i) == Y:
      ans +=1

if ans > 0:
  print('Yes') 
else:
  print('No')

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())

if (x == 1 and y == 2) or (x == 1 and y == 4) or(x==y==0):
    print('Yes')
    quit()

for i in range(x):
    if i * 2 + (x - i) * 4 == y:
        print('Yes')
        quit()
print('No')

Submission status: Wrong Answer

Solution code:
X,Y = input().split()
X = int(X)
Y = int(Y)
if 4*X < Y:
  print('No')
else:
  if Y % 2 != 0:
    print('No')
  else:
    print('Yes')

Submission status: Wrong Answer

Solution code:
X, Y = map(int,input().split())

for i in range(X) :
    if Y -(4*i) == (X-i)*2 :
        print("Yes")
        exit()
    else :
        if Y==2 or Y==4 :
            print("Yes")
            exit()
print("No")

Submission status: Wrong Answer

Solution code:
N, M = map(int,input().split())
crain = (4 * N - M) / 2
if crain.is_integer() and crain >= 0:
    crain = int(crain)
    print("Yes")
else:
    print('No')

Submission status: Wrong Answer

Solution code:
X,Y=map(int,input().split())

def  get_CT(x,y):
  C=(4*x-y)/2
  T=x-C
  if C<=0 and T<=0:
    return 'Yes'
  if C>=0 and T>=0:
    return 'Yes'
  else:
    return 'No'
  
print(get_CT(X,Y))

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
turu = 4
kame = 2
flag = 'No'
for i in range(a+1):
  for j in range(i+1):
    if b == turu * i + kame * j:
      flag = 'Yes'
    if  turu * i + kame * j > 4 * a: break
 
print(flag)

Submission status: Wrong Answer

Solution code:
X,Y = map(int, input().split())

if Y < 4*X and Y % 2 == 0 and Y > 2*X:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
b,t = map(int,input().split())
if t==2:
  print("Yes")
elif t==4:
  print("Yes")

for i in range(b):
  if b*2 == t:
    print("Yes")
    break
  elif b*4 == t:
    print("Yes")
    break
  elif b*6 ==t:
    print("Yes")
    break
  else:
    print("No")
    break

Submission status: Wrong Answer

Solution code:
XY = list(map(int, input().split()))
 
c = 2 * XY[0] - XY[1] / 2
t = - XY[0] + XY[1] / 2
 
if not (isinstance(c, int) and isinstance(t, int)):
  print('No')
elif c == 0 and t == 0:
  print('No')
elif c >= 0 and t >= 0:
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
x,y=list(map(int,input().split()))
sum=0
if x==1:
    if y==2 or y==4:
        print("Yes")
    else:
        print("No")
elif y%2!=0:
    print("No")
else:
    for i in range(x):
        print(i)
        if sum%4==2 and sum!=y:
            sum+=2
            print(sum)
        elif sum%4==0 and sum!=y:
            sum+=4
            print(sum)
    if sum==y:
        print("Yes")
    else:
        print("No")

Submission status: Wrong Answer

Solution code:
s = input().split()
intX = int(s[0])
intY = int(s[1])

q, mod = divmod(intY, 2)
if (mod == 1) : 
    print('No')
    exit()

intB = (intY-2*intX) / 4
q2, mod2 = divmod(intB, 1)
if (mod == 0) : 
    print('Yes')
    exit()
print('No')

Submission status: Wrong Answer

Solution code:
from sys import stdin
x, y = map(int, stdin.readline().rstrip().split())

res = 'No'
if y%2 == 1: #偶数だけ
    print(res)
elif x*4 == y or x*2 ==y:
    print('Yes')
else:
    for i in range(1, x-1):
        if i*4 + (x-i)*2 == y:
            res = 'Yes'

    print(res)

Submission status: Wrong Answer

Solution code:
a,b = map(int, input().split())
i = 0
while i<=a:
  turu = 2*(a-i)
  kame = 4*i
  
  if b == turu:
    print('YES')
    break
    
  if b == kame:
    print('YES')
    break
  
  amari = b - turu

  if kame != 0:
    if amari - kame == 0:
      print('YES')
      break
      
  i = i + 1
  
else:
  print('No')

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())

if (4*x < y) or (y == 0):
    print("No")
    exit()

if (y % 6 == 2) or (y % 6 == 4) or (y % 6 == 0):
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())


if x > 50:
    print("No")        
elif 4 * x < y:
    print("No")
elif y % 2 == 0:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
x,y=map(int,input().split())
a=(2*x-y/2)
b=(y/2-x)
s=2*a+4*b

if a>=0 and b>=0 and a+b==x and s==y :
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
X, Y = map(int, input().split())

crain = (4*X - Y) / 2

if crain.is_integer() and crain >= 0:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
# Xは動物の総数,Yは動物の足の総数
X,Y = map(int, input().split())

# 亀は4本の足を持ち，鶴は2本の足を持つ．
kame = 4
turu = 2

# まずは鶴が1匹の時だけを判定,奇数は有えないので排除
if Y == 2 and X == 1:
  print("Yes")
elif Y == 100 and X*kame < Y:
  print("No")
elif Y % turu != 0:
  print("No")
elif X*kame < Y:
  print("No")
else:
  ans = Y
  while True:
    Y = Y % 2
    ans = ans/2
    if Y != 0:
      print("No")
      break
    elif Y == 0 and ans == 0:
      print("Yes")
      break

Submission status: Wrong Answer

Solution code:
X,Y = [int(i) for i in input().split()]

print ("Yes" if Y%2 == 0 and Y//4 <= X <= Y//2 else "No")

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())
ok = 0
for i in range(x+1):
    for j in range(x-i+1):
        if (2*i + 4*j) == y:
            ok = 1
        
if ok == 1:
    print('Yes')
else:
    print('No')

Submission status: Wrong Answer

Solution code:
x = list(map(int, input().split()))
def func(x):
    for i in range(x[0]+1):
        for j in range(x[0]+1):
            if i+j>x[0]:
                print('No')
                return
                break
            elif i*2 + j*4 == x[1] or j*2 + i*4 == x[1]:
                print('Yes')
                return
    print('No')
    return
func(x)

Submission status: Wrong Answer

Solution code:
#!/usr/bin/env python3
import sys
import numpy as np

YES = "Yes"  # type: str
NO = "No"  # type: str


def solve(X: int, Y: int):
    a = (4*X-Y)/2
    if a.is_integer and a>=0 and a<=X:
        print(YES)
    else:
        print(NO)

    return


# Generated by 1.1.7.1 https://github.com/kyuridenamida/atcoder-tools  (tips: You use the default template now. You can remove this line by using your custom template)
def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    X = int(next(tokens))  # type: int
    Y = int(next(tokens))  # type: int
    solve(X, Y)

if __name__ == '__main__':
    main()

Submission status: Wrong Answer

Solution code:
l,m = map(int,input().split())
a = 0
b = 0

mm = l*4

a = (mm - m) % 2
b = (mm - m) // 2
if a == 0 and abs(b) + (l-b) == l:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
x,y = map(int,input().split())

for i in range(101):
    if 2*i + 4*(x-i) == y:
        print("Yes")
        exit()
        
print("No")

Submission status: Wrong Answer

Solution code:
X, Y = map(int, input().split())

for i in range(X):
    if i*4 + (X-i)*2 == Y:
        print('Yes')
        exit()
print('No')

Submission status: Wrong Answer

Solution code:
import math
X, Y = map(int,input().split())
ans = "No"
for i in range(X):
  if(2*X+2*i==Y):
    ans = "Yes"
print(ans)

Submission status: Wrong Answer

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

ans=4*x-y
if ans%2==0 and ans>=0:print("Yes")
else:print("No")

Submission status: Wrong Answer

Solution code:
import sys
X,Y = map(int,input().split())
y = Y / 2
if Y % 2 != 0:
    print("No")

for i in range(0,X + 1):
    for j in range(0,X + 1):
        if Y == 2 * i + 4 * j:
            print("Yes")
            sys.exit()
print("No")

Submission status: Wrong Answer

Solution code:
x,y=(int(x) for x in input().split())
ans = y / 2 - x
if ans <= x and ans.is_integer() == True:
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

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

q, mod = divmod(foot, 4)

if foot > N*4:
  print("No")
elif foot % 2 ==1:
  print("No")
elif q > N:
  print("No")
else:
  print("Yes")

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
turu = 4
kame = 2
flag = 'No'
for i in range(a+1):
  for j in range(i+1):
    if  turu * i + kame * j > 4 * a: break
    if b == turu * i + kame * j:
      flag = 'Yes'
 
print(flag)

Submission status: Wrong Answer

Solution code:
x,y=input().split()
x=int(x)
y=int(y)
f=0
for i in range(x+1):
  for j in range(x+1):
    if(((2*i)+(4*j))==y):
      f=1;
      break
if(f==1):
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

Solution code:
import sys
X, Y = map(int, input().split())

crane = [x for x in range(X+1)]
turtle = [x for x in range(X+1)]

for c in crane:
    for t in turtle:
        if c + t == 0:
            break
        if c + t > X:
            break
        if c*2 + t*4 == Y:
            print("Yes")
            sys.exit(0)
            
print("No")

Submission status: Wrong Answer

Solution code:
N, M = map(int,input().split())
crain = (4 * N - M) / 2
if crain.is_integer() and crain > 0:
    crain = int(crain)
    print("Yes")
else:
    print('No')

Submission status: Wrong Answer

Solution code:
x ,y = map(int, input().split())
 
sun = 0
flag = True
for i in range(0, x+1):
    sum = i*2
    if sum == y:
        print('Yes')
        flag = False
        break
    for j in range(0, x+1):
        if i+j >x:
            break
        if not j == 0:
            sum += 4
        if sum == y:
            print('Yes')
            flag = False
            break
if flag:
    print('No')

Submission status: Wrong Answer

Solution code:
import sys
X, Y = map(int, input().split())

if X > 50 or Y%2 == 1 or 2*X>Y or 4*X<Y:
    print('No')
    sys.exit()


for i in range(2 ** X):
    food = 0
    for j in range(X):  
        if ((i >> j) & 1):  
            food +=2
        else:
            food+=4
    if food == Y:
        print('Yes')
        sys.exit()
    if food > Y:
        print('No')
        sys.exit()
print("No")

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())
aa =  y - 2 * x
a = aa / 2
b = x - a
print("Yes" if 0 <= a <= x and 0 <= b <= x else 'No')

Submission status: Wrong Answer

Solution code:
x,y=(int(x) for x in input().split())
1<=x<=100
1<=y<=100
if y>x*6:
    print('No')
elif y<x*2:
    print('No')
elif y%2==1:
    print('No')
elif y==4 and x==1:
    print('No')
else:
    print('Yes')

Submission status: Wrong Answer

Solution code:
z=[]
x, y= map(int,input().split())
for i in range(x):
    if (2*i)+(4*(x-i))==y:
        z.append('1')
    if (4*i)+(2*(x-i))==y:
        z.append('1')
        

if len(z)>0:
    print('YES')

if len(z)<=0:
    print('NO')

Submission status: Wrong Answer

Solution code:
import sys

X, Y = map(int, input().split(" "))

for t in range(X + 1):
    for c in range(X + 1):
        if Y == ((t * 4) + (c * 2)):
            print("Yes")
            sys.exit()

print("No")

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
if a*4 >=b:
    if b%4== 2:
        print('Yes')
    if b%4== 0:
        print('Yes')
    if b%4== 1:
        print('No')
    if b%4 ==3:
        print('No')
else:
    print('No')

Submission status: Wrong Answer

Solution code:
X, Y = map(int, input().split())

if 4 * X - Y <= 0:
        print("No")
        exit()

if (4 * X - Y)  % 2 == 0:
        tsuru = (4 * X - Y) // 2
        kame = X - tsuru
        if kame * 4 + tsuru * 2 == Y:
                print("Yes")
                exit()
        else:
                print("No")
                exit()
else:
        print("No")
        exit()

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())

if (x == 1 and y == 2) or (x == 1 and y == 4):
    print('Yes')
    quit()

for i in range(x):
    if i * 2 + (x - i) * 4 == y:
        print('Yes')
        quit()
print('No')

Submission status: Wrong Answer

Solution code:
#!/usr/bin/env python3
import sys
import numpy as np

YES = "Yes"  # type: str
NO = "No"  # type: str


def solve(X: int, Y: int):
    a = (4*X-Y)/2
    if a.is_integer and a>0 and a<=X:
        print(YES)
    else:
        b = (2*X-Y)/4
        if b.is_integer and b>0 and b<=X:
            print(YES)
        else:
            print(NO)

    return


# Generated by 1.1.7.1 https://github.com/kyuridenamida/atcoder-tools  (tips: You use the default template now. You can remove this line by using your custom template)
def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    X = int(next(tokens))  # type: int
    Y = int(next(tokens))  # type: int
    solve(X, Y)

if __name__ == '__main__':
    main()