
object Main extends App {

  val sc = new java.util.Scanner(System.in)
  val N = sc.nextInt()
  var A = sc.nextInt()
  var B = sc.nextInt()
  val S = sc.next().toList
  val results = S.map(i => {
    i match {
      case 'a' => {
        if (A + B > 0) {
          A -= 1
          "Yes"
        } else {
          "No"
        }
      }
      case 'b' => {
        if (A + B > 0 && B > 0) {
          B -= 1
          "Yes"
        } else {
          "No"
        }
      }
      case 'c' => "No"      
    }
  })
  results.foreach(println)
}