a,b=map(int, input().split())
s=str(input())
b=b-1
slist=list(s)
if slist[b]=="A":
  slist[b]="a"
if slist[b]=="B":
  slist[b]="b"
if slist[b]=="C":
  slist[b]="c"
s="".join(slist)
print(s) a,b=map(int, input().split()) a map(int, input().split()) map int input().split() ().split () input split b s=str(input()) s str(input()) str input() input b=b-1 b b-1 b 1 slist=list(s) slist list(s) list s if slist[b]=="A":
  slist[b]="a" slist[b]=="A" slist[b] slist b "A" slist[b]="a" slist[b] slist b "a" if slist[b]=="B":
  slist[b]="b" slist[b]=="B" slist[b] slist b "B" slist[b]="b" slist[b] slist b "b" if slist[b]=="C":
  slist[b]="c" slist[b]=="C" slist[b] slist b "C" slist[b]="c" slist[b] slist b "c" s="".join(slist) s "".join(slist) "".join "" join slist print(s) print s b=map(int, input().split()) map(int, input().split()) b slist=list(s) list(s) slist b=b-1 b-1 b s="".join(slist) "".join(slist) s s=str(input()) str(input()) s a,b=map(int, input().split()) map(int, input().split()) a
a,b=map(int, input().split())
s=str(input())
b=b-1
slist=list(s)
if slist[b]=="A":
  slist[b]="a"
if slist[b]=="B":
  slist[b]="b"
if slist[b]=="C":
  slist[b]="c"
s="".join(slist)
print(s)