n = int(input())

a = list(map(int, input().split()))

q = int(input())

m = dict(zip(range(q), list(map(int, input().split()))))

ans = ["no"] * q

for i in range(2**n):
    now = 0
    for j in range(n):
        if i >> j & 1:
            now += a[j]

    if now in m.values():
        key_lst = [key for key, value in m.items() if value==now]
        for key in key_lst:
            ans[key] = "yes"

for i in range(q):
    print(ans[i])
 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 = dict(zip(range(q), list(map(int, input().split())))) m dict(zip(range(q), list(map(int, input().split())))) dict zip(range(q), list(map(int, input().split()))) zip range(q) range q list(map(int, input().split())) list map(int, input().split()) map int input().split() ().split () input split ans = ["no"] * q ans ["no"] * q ["no"] "no" q for i in range(2**n):
    now = 0
    for j in range(n):
        if i >> j & 1:
            now += a[j]

    if now in m.values():
        key_lst = [key for key, value in m.items() if value==now]
        for key in key_lst:
            ans[key] = "yes" i range(2**n) range 2**n 2 n now = 0 now 0 for j in range(n):
        if i >> j & 1:
            now += a[j]

     j range(n) range n if i >> j & 1:
            now += a[j]

     i >> j & 1 i >> j i j 1 now += a[j] now a[j] a j if now in m.values():
        key_lst = [key for key, value in m.items() if value==now]
        for key in key_lst:
            ans[key] = "yes" now in m.values() now m.values() m.values m values key for key, value in m.items() if value==now for key, value in m.items() if value==now key value m.items() m.items m items value==now value now if value==now key key_lst = [key for key, value in m.items() if value==now] key_lst [key for key, value in m.items() if value==now] for key in key_lst:
            ans[key] = "yes" key key_lst ans[key] = "yes" ans[key] ans key "yes" for i in range(q):
    print(ans[i]) i range(q) range q print(ans[i]) print ans[i] ans i now = 0 0 now n = int(input()) int(input()) n key_lst = [key for key, value in m.items() if value==now] [key for key, value in m.items() if value==now] key_lst m = dict(zip(range(q), list(map(int, input().split())))) dict(zip(range(q), list(map(int, input().split())))) m a = list(map(int, input().split())) list(map(int, input().split())) a q = int(input()) int(input()) q now += a[j] a[j] now ans = ["no"] * q ["no"] * q ans
n = int(input())

a = list(map(int, input().split()))

q = int(input())

m = dict(zip(range(q), list(map(int, input().split()))))

ans = ["no"] * q

for i in range(2**n):
    now = 0
    for j in range(n):
        if i >> j & 1:
            now += a[j]

    if now in m.values():
        key_lst = [key for key, value in m.items() if value==now]
        for key in key_lst:
            ans[key] = "yes"

for i in range(q):
    print(ans[i])

