sum = 1
input()
for i in map(int,input().split()):
    sum|=sum<<i
input()
for j in map(int,input().split()):
    print(['no','yes'][(sum>>j)&1]) sum = 1 sum 1 input() input for i in map(int,input().split()):
    sum|=sum<<i i map(int,input().split()) map int input().split() ().split () input split sum|=sum<<i sum sum<<i sum i input() input for j in map(int,input().split()):
    print(['no','yes'][(sum>>j)&1]) j map(int,input().split()) map int input().split() ().split () input split print(['no','yes'][(sum>>j)&1]) print ['no','yes'][(sum>>j)&1] ['no','yes'] 'no' 'yes' (sum>>j)&1 sum>>j sum j 1 sum|=sum<<i sum<<i sum sum = 1 1 sum
sum = 1
input()
for i in map(int,input().split()):
    sum|=sum<<i
input()
for j in map(int,input().split()):
    print(['no','yes'][(sum>>j)&1])
