n,k=map(int,input().split())
def replace(m):
  if m=="A":
    return "a"
  elif m=="B":
    return "b"
  else:
    return "c"
  
abc_str=list(input())
abc_str[k-1]=replace(abc_str[k-1])
abc_str="".join(abc_str)
print(abc_str) n,k=map(int,input().split()) n map(int,input().split()) map int input().split() ().split () input split k def replace(m):
  if m=="A":
    return "a"
  elif m=="B":
    return "b"
  else:
    return "c"
   replace if m=="A":
    return "a"
  elif m=="B":
    return "b"
  else:
    return "c"
   m=="A" m "A" return "a" "a" elif m=="B":
    return "b"
   m=="B" m "B" return "b" "b" return "c" "c" m m abc_str=list(input()) abc_str list(input()) list input() input abc_str[k-1]=replace(abc_str[k-1]) abc_str[k-1] abc_str k-1 k 1 replace(abc_str[k-1]) replace abc_str[k-1] abc_str k-1 k 1 abc_str="".join(abc_str) abc_str "".join(abc_str) "".join "" join abc_str print(abc_str) print abc_str abc_str=list(input()) list(input()) abc_str n,k=map(int,input().split()) map(int,input().split()) n abc_str="".join(abc_str) "".join(abc_str) abc_str k=map(int,input().split()) map(int,input().split()) k def replace(m):
  if m=="A":
    return "a"
  elif m=="B":
    return "b"
  else:
    return "c"
   def replace(m):
  if m=="A":
    return "a"
  elif m=="B":
    return "b"
  else:
    return "c"
   replace
n,k=map(int,input().split())
def replace(m):
  if m=="A":
    return "a"
  elif m=="B":
    return "b"
  else:
    return "c"
  
abc_str=list(input())
abc_str[k-1]=replace(abc_str[k-1])
abc_str="".join(abc_str)
print(abc_str)