n, m, q = gets.split.map(&:to_i)
arr1 = gets.split.map(&:to_i)
arr2 = gets.split.map(&:to_i)
baton, member = 0, [*0...n]

m.times do |i|
  baton = arr1[i].even? ? (baton + arr1[i]) % (n - i) : (baton - arr1[i]) % (n - i)
  member.delete_at(baton)
end

arr2.each do |elm|
  puts member.include?(elm) ? 1 : 0
end