n = int(input())
A = list(map(int, input().split()))
q = int(input())
M = list(map(int, input().split()))

for x in M:
  dp = [[0 for _ in range(x+1)] for _ in range(n+1)]
  dp[0][0]=1
  for i in range(n):
    for j in range(x+1):
      if A[i] <= j:
        dp[i+1][j] = dp[i][j - A[i]] or dp[i][j]
      else:
        dp[i+1][j] = dp[i][j]

  if dp[n][x] == 1:
    print ('yes')
  else:
    print ('no') 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 for x in M:
  dp = [[0 for _ in range(x+1)] for _ in range(n+1)]
  dp[0][0]=1
  for i in range(n):
    for j in range(x+1):
      if A[i] <= j:
        dp[i+1][j] = dp[i][j - A[i]] or dp[i][j]
      else:
        dp[i+1][j] = dp[i][j]

  if dp[n][x] == 1:
    print ('yes')
  else:
    print ('no') x M [0 for _ in range(x+1)] for _ in range(n+1) for _ in range(n+1) _ range(n+1) range n+1 n 1 for _ in range(n+1) [0 for _ in range(x+1)] dp = [[0 for _ in range(x+1)] for _ in range(n+1)] dp [[0 for _ in range(x+1)] for _ in range(n+1)] dp[0][0]=1 dp[0][0] [0] dp 0 0 1 for i in range(n):
    for j in range(x+1):
      if A[i] <= j:
        dp[i+1][j] = dp[i][j - A[i]] or dp[i][j]
      else:
        dp[i+1][j] = dp[i][j]

   i range(n) range n for j in range(x+1):
      if A[i] <= j:
        dp[i+1][j] = dp[i][j - A[i]] or dp[i][j]
      else:
        dp[i+1][j] = dp[i][j]

   j range(x+1) range x+1 x 1 if A[i] <= j:
        dp[i+1][j] = dp[i][j - A[i]] or dp[i][j]
      else:
        dp[i+1][j] = dp[i][j]

   A[i] <= j A[i] A i j dp[i+1][j] = dp[i][j - A[i]] or dp[i][j] dp[i+1][j] [i+1] dp i+1 i 1 j dp[i][j - A[i]] or dp[i][j] dp[i][j - A[i]] [i] dp i j - A[i] j A[i] A i dp[i][j] [i] dp i j dp[i+1][j] = dp[i][j] dp[i+1][j] [i+1] dp i+1 i 1 j dp[i][j] [i] dp i j if dp[n][x] == 1:
    print ('yes')
  else:
    print ('no') dp[n][x] == 1 dp[n][x] [n] dp n x 1 print ('yes') print 'yes' print ('no') print 'no' A = list(map(int, input().split())) list(map(int, input().split())) A n = int(input()) int(input()) n dp = [[0 for _ in range(x+1)] for _ in range(n+1)] [[0 for _ in range(x+1)] for _ in range(n+1)] dp M = list(map(int, input().split())) list(map(int, input().split())) M q = int(input()) int(input()) q
n = int(input())
A = list(map(int, input().split()))
q = int(input())
M = list(map(int, input().split()))

for x in M:
  dp = [[0 for _ in range(x+1)] for _ in range(n+1)]
  dp[0][0]=1
  for i in range(n):
    for j in range(x+1):
      if A[i] <= j:
        dp[i+1][j] = dp[i][j - A[i]] or dp[i][j]
      else:
        dp[i+1][j] = dp[i][j]

  if dp[n][x] == 1:
    print ('yes')
  else:
    print ('no')
