# frozen_string_literal: true

require 'set'

gets
arr = gets.split(' ').map(&:to_i)
cand = Set[0]
arr.each do |ai|
  togo = Set.new
  cand.each do |c|
    togo.add(c + ai) unless cand.include?(c + ai)
  end
  cand |= togo
end
gets
res = gets.split(' ').map(&:to_i)
puts res.map { |mi| cand.include?(mi) ? 'yes' : 'no' }.join("\n")

