from sys import stdin, stderr
from functools import lru_cache

@lru_cache(maxsize=None)
def rec(i, m):
    if i == 0:
        return m == 0 or A[i] == m

    return rec(i - 1, m) or rec(i - 1, m - A[i])

n = int(input())
A = [int(i) for i in input().split()]
q = int(input())
M = [int(i) for i in input().split()]

for m in M:
    if rec(n - 1, m):
        print('yes')
    else:
        print('no') from sys import stdin, stderr from functools import lru_cache def rec(i, m):
    if i == 0:
        return m == 0 or A[i] == m

    return rec(i - 1, m) or rec(i - 1, m - A[i]) rec if i == 0:
        return m == 0 or A[i] == m

     i == 0 i 0 return m == 0 or A[i] == m m == 0 or A[i] == m m == 0 m 0 A[i] == m A[i] A i m return rec(i - 1, m) or rec(i - 1, m - A[i]) rec(i - 1, m) or rec(i - 1, m - A[i]) rec(i - 1, m) rec i - 1 i 1 m rec(i - 1, m - A[i]) rec i - 1 i 1 m - A[i] m A[i] A i i i m m @lru_cache(maxsize=None) rec maxsize=None @lru_cache(maxsize=None) lru_cache maxsize=None maxsize None rec n = int(input()) n int(input()) int input() input int(i) for i in input().split() for i in input().split() i input().split() ().split () input split for i in input().split() int(i) int i A = [int(i) for i in input().split()] A [int(i) for i in input().split()] q = int(input()) q int(input()) int input() input int(i) for i in input().split() for i in input().split() i input().split() ().split () input split for i in input().split() int(i) int i M = [int(i) for i in input().split()] M [int(i) for i in input().split()] for m in M:
    if rec(n - 1, m):
        print('yes')
    else:
        print('no') m M if rec(n - 1, m):
        print('yes')
    else:
        print('no') rec(n - 1, m) rec n - 1 n 1 m print('yes') print 'yes' print('no') print 'no' n = int(input()) int(input()) n A = [int(i) for i in input().split()] [int(i) for i in input().split()] A M = [int(i) for i in input().split()] [int(i) for i in input().split()] M def rec(i, m):
    if i == 0:
        return m == 0 or A[i] == m

    return rec(i - 1, m) or rec(i - 1, m - A[i]) def rec(i, m):
    if i == 0:
        return m == 0 or A[i] == m

    return rec(i - 1, m) or rec(i - 1, m - A[i]) rec q = int(input()) int(input()) q
from sys import stdin, stderr
from functools import lru_cache

@lru_cache(maxsize=None)
def rec(i, m):
    if i == 0:
        return m == 0 or A[i] == m

    return rec(i - 1, m) or rec(i - 1, m - A[i])

n = int(input())
A = [int(i) for i in input().split()]
q = int(input())
M = [int(i) for i in input().split()]

for m in M:
    if rec(n - 1, m):
        print('yes')
    else:
        print('no')