read n a b
check=0
b_chk=0
for i in `fold -1`
do
	case ${i} in
		a)
			if [ $check -lt $((a + b)) ]
			then
				echo Yes
				check=$((check + 1))
			else
				echo No
			fi
		;;
		b)
			if [ $check -lt $((a + b)) -a $b_chk -lt $b ]
			then
				echo Yes
				check=$((check + 1))
				b_chk=$((b_chk + 1))
			else
				echo No
			fi
		;;
		c)
			echo No
		;;
	esac
done
