def can_sum?(n, sequence, tail)
	return false if tail < 0

	n_tmp = n
	tail.downto(0) do |i|
		next if n_tmp < sequence[i]
		n_tmp -= sequence[i]
		return true if n_tmp == 0
	end

	can_sum?(n, sequence, tail - 1)
end

n = STDIN.gets.to_i
sequence = STDIN.gets.split[0...n].map(&:to_i)
m = STDIN.gets.to_i
questions = STDIN.gets.split[0...m].map(&:to_i)

sequence.sort!
questions.each do |q|
	i = sequence.find_index { |num| num > q }
	i = sequence.size if !i
	puts can_sum?(q, sequence, i - 1) ? "yes" : "no"
end