n, a, b = list(map(int, input().split()))

s_l  = eval(input())

ca = 0

cb = 0

for s in s_l:

  if s == 'a' and ca + cb < a+b:

    ca += 1

    print('Yes')

  elif s == 'b' and ca + cb < a+b and cb < b:

    cb += 1

    print('Yes')

  else:

    print('No')
n, a, b = list(map(int, input().split()))

s = eval(input())

jap_c = 0

ab_c = 0

for i in list(s):

    if i == 'a':

        if jap_c + ab_c < a+b:

            jap_c += 1

            print('Yes')

            continue

    if i == 'b':

        if jap_c + ab_c < a+b:

            if ab_c < b:

                ab_c += 1

                print('Yes')

                continue

    print('No')
n, a, b = list(map(int, input().split()))
s_l = eval(input())
ca = 0
cb = 0
for s in s_l:
    if s == "a" and ca + cb < a + b:
        ca += 1
        print("Yes")
    elif s == "b" and ca + cb < a + b and cb < b:
        cb += 1
        print("Yes")
    else:
        print("No")

n, a, b = list(map(int, input().split()))
s = eval(input())
jap_c = 0
ab_c = 0
for i in list(s):
    if i == "a":
        if jap_c + ab_c < a + b:
            jap_c += 1
            print("Yes")
            continue
    if i == "b":
        if jap_c + ab_c < a + b:
            if ab_c < b:
                ab_c += 1
                print("Yes")
                continue
    print("No")

-s_l = eval(input()) -ca = 0 -cb = 0 -for s in s_l: -    if s == "a" and ca + cb < a + b: -        ca += 1 -        print("Yes") -    elif s == "b" and ca + cb < a + b and cb < b: -        cb += 1 -        print("Yes") -    else: -        print("No") +s = eval(input()) +jap_c = 0 +ab_c = 0 +for i in list(s): +    if i == "a": +        if jap_c + ab_c < a + b: +            jap_c += 1 +            print("Yes") +            continue +    if i == "b": +        if jap_c + ab_c < a + b: +            if ab_c < b: +                ab_c += 1 +                print("Yes") +                continue +    print("No")