#!/usr/local/gnu/bin/bash
read n a b
s=(`fold -1`)
an=0
bn=0
for x in ${s[@]}
do
    case $x in
        "a" )
            if((an+bn<a+b))
            then
                an=$((an+1))
                echo Yes
            else
                echo No
            fi;;
        "b" )
            if((an+bn<a+b&&bn<b))
            then
                bn=$((bn+1))
                echo Yes
            else
                echo No
            fi;;
        "c" )
            echo No;;
    esac
done
