n = gets.to_i
A = gets.split.map(&:to_i)
q = gets.to_i
M = gets.split.map(&:to_i)

def solve(i, m)
  return true if m == 0
  return false if i >= A.size

  solve(i + 1, m) || solve(i + 1, m - A[i])
end

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