import scala.io.StdIn

object Main {
  def main(args: Array[String]): Unit = {
    val length = StdIn.readInt
    val array = StdIn.readLine().split(" ").map(_.toInt)
    val problemLen = StdIn.readInt
    val problemArray = StdIn.readLine().split(" ").map(_.toInt)

    for (m <- problemArray) if (solve(0, m, array)) println("yes") else println("no")

  }

  def solve (i: Int, m: Int, array: Array[Int]): Boolean = {
    if (m == 0) return true
    if (i >= array.length) return false
    solve(i + 1, m, array) || solve(i + 1, m - array(i), array)
  }
}