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)

combination = []
1.upto(n) do |i|
	sequence.combination(i).each { |e| combination << e.inject(:+) }
end

questions.each do |q|
	puts combination.find { |c| q == c } ? "yes" : "no"
end