n = gets.to_i
sources = gets.split.map(&:to_i)
q = gets.to_i
targets = gets.split.map(&:to_i)

solve = lambda do |i, m|
  return true if m == 0
  return false if i >= n

  solve.call(i + 1, m) || solve.call(i + 1, m - sources[i])
end

targets.each do |target|
  puts solve.call(0, target) ? 'yes' : 'no'
end