n = gets.to_i
aArr = gets.split.map(&:to_i).sort.reverse
q = gets.to_i
mArr = gets.split.map(&:to_i)

ans = [0]
aArr.each do |a|
  ans += ans.map{|x| x+a}
  ans = ans.select{|x| x<=2000}.uniq
end
mArr.each do |m|
  printf("%s\n",ans.include?(m) ? "yes" : "no")
end
