#include<stdio.h>
#include<string.h>
#include<stdlib.h>
#define MAX 2001
int exsearch(int*, int, int, int(*)[MAX]);
main()
{
        int i, n, q, m, *a, (*c)[MAX];
        scanf("%d", &n);
        a = (int*)malloc(sizeof(int) * n);
        c = (int(*)[2001])malloc(sizeof(int) * n * MAX);
        for(i = 0; i < n; i++){
        scanf("%d%*c", &a[i]);
        memset(c[i], -1, sizeof(c[i]));
        }
        scanf("%d", &q);
        for(i = 0; i < q; i++){
                scanf("%d%*c", &m);
                if(exsearch(a, m, n, c)){
                        printf("yes\n");
                }else{
                        printf("no\n");
                }
        }
        free(a);
        free(c);
}
int exsearch(int *a, int m, int n, int(*c)[MAX])
{
        if(!m){
        return 1;
        }else if(!n || m < 0 ){
                return 0;
        }else if(c[n- 1][m] != -1){
                return c[n-1][m];
        }else{
                c[n-1][m] = exsearch(a, m - a[n - 1], n - 1, c) ||
                        exsearch(a, m, n - 1, c);
        }
        return c[n-1][m];
}