Problem: Boboniu gives you

  * r red balls, 
  * g green balls, 
  * b blue balls, 
  * w white balls. 



He allows you to do the following operation as many times as you want: 

  * Pick a red ball, a green ball, and a blue ball and then change their color to white. 



You should answer if it's possible to arrange all the balls into a palindrome after several (possibly zero) number of described operations. 

Input

The first line contains one integer T (1≤ T≤ 100) denoting the number of test cases.

For each of the next T cases, the first line contains four integers r, g, b and w (0≤ r,g,b,w≤ 10^9).

Output

For each test case, print "Yes" if it's possible to arrange all the balls into a palindrome after doing several (possibly zero) number of described operations. Otherwise, print "No".

Example

Input


4
0 1 1 1
8 1 9 3
0 0 0 0
1000000000 1000000000 1000000000 1000000000


Output


No
Yes
Yes
Yes

Note

In the first test case, you're not able to do any operation and you can never arrange three balls of distinct colors into a palindrome.

In the second test case, after doing one operation, changing (8,1,9,3) to (7,0,8,6), one of those possible palindromes may be "rrrwwwbbbbrbbbbwwwrrr".

A palindrome is a word, phrase, or sequence that reads the same backwards as forwards. For example, "rggbwbggr", "b", "gg" are palindromes while "rgbb", "gbbgr" are not. Notice that an empty word, phrase, or sequence is palindrome.

Solution (in PYTHON3):

Solution:
# def seg_tree(arr,l,r,seg,ind):
#     if l==r:
#         seg[ind] = arr[l]

#     else:
#         mid = (l+r)//2

#         seg_tree(arr,l,mid,seg,2*ind+1)
#         seg_tree(arr,mid+1,r,seg,2*ind+2)

#         seg[ind] = seg[2*ind+1]+seg[2*ind+2]

# def get_sum(l1,r1,l2,r2,seg,ind):
    
#     if l1==l2 and r1==r2:
#         return seg[ind]
#     elif l1 > r1:
#         return 0
#     else:
#         mid = (l2+r2)//2
#         return get_sum(l1,min(r1,mid),l2,mid,seg,2*ind+1) + get_sum(max(l1,mid+1),r1,mid+1,r2,seg,2*ind+2)

# def modify(l,r,seg,arr,pos,val,ind):
#     if l==r:
#         seg[ind] = val
#         arr[pos] = val
#     else:
#         mid = (l+r)//2

#         if pos <= mid:
#             modify(l,mid,seg,arr,pos,val,2*ind+1)
#         else:
#             modify(mid+1,r,seg,arr,pos,val,2*ind+2)

#         seg[ind] = seg[2*ind+1]+seg[2*ind+2]


# n,q = map(int,input().split())

# arr = [0]*n

# seg = [None]*(4*len(arr))

# seg_tree(arr,0,len(arr)-1,seg,0)

# for i in range(q):
#     a,b,c = input().split()

#     if a=="a":
#         modify(0,len(arr)-1,seg,arr,int(b)-1,(arr[int(b)-1]+int(c))%2,0)
#     else:
#         print(int(c)+1-int(b) - get_sum(int(b)-1,int(c)-1,0,len(arr)-1,seg,0))

# def dijksta(graph,edge,n):

#     Unvisit = {(0,0)}
#     dist = [0]*n
#     for i in range(1,n):
#         Unvisit.add((10000000000,i))
#         dist[i] = 10000000000


#     while  Unvisit:

#         x = min(Unvisit)
#         Unvisit.remove(x)

#         u = x[1]
#         d = x[0]

#         for v in graph[u]:
#             if dist[u] + edge[u][v] < dist[v]:
#                 Unvisit.remove((dist[v],v))
#                 dist[v] =  dist[u] + edge[u][v]
#                 Unvisit.add((dist[v],v))
#     return dist[n-1]


# def power(x):
#     if x==0:
#         return 1
#     elif x==1:
#         return 2
#     else:
#         if x%2==0:
#             a = power(x//2)
#             a = a%1000000007
#             return (a*a)%1000000007
#         else:
#             a = power(x//2)
#             a = a%1000000007
#             return (2*a*a)%1000000007



for _ in range(int(input())):
    r,g,b,w = map(int,input().split())

    odd = 0

    if r%2==1:
        odd+=1
    if g%2==1:
        odd+=1
    if b%2==1:
        odd+=1
    if w%2==1:
        odd+=1

    if odd==1 or odd==0:
        print("YES")
    elif odd==2:
        print("NO")
    elif odd==3 and min(r,g,b)>=1:
        print("YES")
    elif odd==4 and min(r,g,b)>=1:
        print("YES")
    else:
        print("NO")