# -*- coding: utf-8 -*-
"""
Created on Wed May  2 21:28:06 2018
ALDS1_5a_r1  
@author: maezawa
"""
import itertools as itr

n = int(input())
a = list(map(int, input().split()))
q = int(input())
m = list(map(int, input().split()))

sum_array = []
for r in range(1,n+1):
    for comb in itr.combinations(a, r):
        sum_array.append(sum(comb))
sum_array.sort()

for i in m:
    left = 0
    right = len(sum_array)
    yesorno = 'no'
    while(left < right):
        #print(left, right)
        mid = (left+right)//2
        if sum_array[mid] == i:
            yesorno = 'yes'
            break
        elif sum_array[mid] > i:
            right = mid
        else:
            left = mid+1
            
    print(yesorno)
 """
Created on Wed May  2 21:28:06 2018
ALDS1_5a_r1  
@author: maezawa
""" import itertools as itr itertools n = int(input()) n int(input()) int input() input a = list(map(int, input().split())) a list(map(int, input().split())) list map(int, input().split()) map int input().split() ().split () input split q = int(input()) q int(input()) int input() input m = list(map(int, input().split())) m list(map(int, input().split())) list map(int, input().split()) map int input().split() ().split () input split sum_array = [] sum_array [] for r in range(1,n+1):
    for comb in itr.combinations(a, r):
        sum_array.append(sum(comb)) r range(1,n+1) range 1 n+1 n 1 for comb in itr.combinations(a, r):
        sum_array.append(sum(comb)) comb itr.combinations(a, r) itr.combinations itr combinations a r sum_array.append(sum(comb)) sum_array.append sum_array append sum(comb) sum comb sum_array.sort() sum_array.sort sum_array sort for i in m:
    left = 0
    right = len(sum_array)
    yesorno = 'no'
    while(left < right):
        #print(left, right)
        mid = (left+right)//2
        if sum_array[mid] == i:
            yesorno = 'yes'
            break
        elif sum_array[mid] > i:
            right = mid
        else:
            left = mid+1
            
    print(yesorno) i m left = 0 left 0 right = len(sum_array) right len(sum_array) len sum_array yesorno = 'no' yesorno 'no' while(left < right):
        #print(left, right)
        mid = (left+right)//2
        if sum_array[mid] == i:
            yesorno = 'yes'
            break
        elif sum_array[mid] > i:
            right = mid
        else:
            left = mid+1
            
     left < right left right mid = (left+right)//2 mid (left+right)//2 left+right left right 2 if sum_array[mid] == i:
            yesorno = 'yes'
            break
        elif sum_array[mid] > i:
            right = mid
        else:
            left = mid+1
            
     sum_array[mid] == i sum_array[mid] sum_array mid i yesorno = 'yes' yesorno 'yes' break elif sum_array[mid] > i:
            right = mid
         sum_array[mid] > i sum_array[mid] sum_array mid i right = mid right mid left = mid+1 left mid+1 mid 1 print(yesorno) print yesorno q = int(input()) int(input()) q yesorno = 'no' 'no' yesorno yesorno = 'yes' 'yes' yesorno right = mid mid right right = len(sum_array) len(sum_array) right left = 0 0 left n = int(input()) int(input()) n mid = (left+right)//2 (left+right)//2 mid a = list(map(int, input().split())) list(map(int, input().split())) a sum_array = [] [] sum_array left = mid+1 mid+1 left m = list(map(int, input().split())) list(map(int, input().split())) m
# -*- coding: utf-8 -*-
"""
Created on Wed May  2 21:28:06 2018
ALDS1_5a_r1  
@author: maezawa
"""
import itertools as itr

n = int(input())
a = list(map(int, input().split()))
q = int(input())
m = list(map(int, input().split()))

sum_array = []
for r in range(1,n+1):
    for comb in itr.combinations(a, r):
        sum_array.append(sum(comb))
sum_array.sort()

for i in m:
    left = 0
    right = len(sum_array)
    yesorno = 'no'
    while(left < right):
        #print(left, right)
        mid = (left+right)//2
        if sum_array[mid] == i:
            yesorno = 'yes'
            break
        elif sum_array[mid] > i:
            right = mid
        else:
            left = mid+1
            
    print(yesorno)

