#include <stdio.h>
#include <stdlib.h>
#include <string.h>

#define iin(x) scanf("%d", &x)
#define lin(x) scanf("%lld", &x)
#define fin(x) scanf("%lf", &x)

#define iout(x) printf("%d", x)
#define lout(x) printf("%d", x)
#define fout(x) printf("%.10f", x)
#define _ putchar(' ')
#define endl puts("")

#define REP(i, x, n) for(i = (x); i < (n); i++)
#define rep(i, n) REP(i, 0, n)

int n, q;
int A[22], m;
int sum[1<<22] = {};

int main() {
  int i, j, k;

  iin(n);
  rep(i, n) iin(A[i]);

  rep(i, 1<<n) {
    rep(j, n) if((i>>j)&1) sum[i] += A[j];
  }
  
  iin(q);  
  rep(i, q) {
    int flag = 0;
    iin(m);
    rep(j, 1<<n) {
      if(sum[j] == m) {
	flag = 1;
	break;
      }
    }
    puts((flag ? "yes" : "no"));
  }

  
  
  return 0;
}