/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

/* 
 * File:   main.c
 * Author: Ivan
 *
 * Created on July 2, 2018, 2:54 PM
 */

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

/*
 * 
 */

int canMake(int index, int M, int *A, int size);

int main(int argc, char** argv) {
    int n, q;
    int *A, *M;
    scanf("%d", &n);
    A = (int *)malloc(sizeof(int) * n);
    for (int i = 0; i < n; ++i) scanf("%d", &A[i]);
    scanf("%d", &q);
    M = (int *)malloc(sizeof(int) * q);
    for (int j = 0; j < q; ++j) scanf("%d", &M[j]);
    
    for (int ix = 0; ix < q; ++ix)
    {
    if ( canMake(0, M[ix], A, n)) printf("yes\n");
    else { printf("no\n"); }
    }
    
    return (EXIT_SUCCESS);
}

int canMake(int index, int M, int *A, int size)
{
    if (M == 0) return 1;
    if (index >= size) return 0;
    int result = canMake(index+1, M, A, size) || canMake(index+1, M - A[index], A, size);
    return result;
}
