N,K=list(map(int,input().split()))
S = list(input())

for i in range(len(S)):
    if i != K-1:
        print(S[i],end='')
    else:
        print(chr(ord(S[i])+32),end="") N,K=list(map(int,input().split())) N list(map(int,input().split())) list map(int,input().split()) map int input().split() ().split () input split K S = list(input()) S list(input()) list input() input for i in range(len(S)):
    if i != K-1:
        print(S[i],end='')
    else:
        print(chr(ord(S[i])+32),end="") i range(len(S)) range len(S) len S if i != K-1:
        print(S[i],end='')
    else:
        print(chr(ord(S[i])+32),end="") i != K-1 i K-1 K 1 print(S[i],end='') print S[i] S i end='' end '' print(chr(ord(S[i])+32),end="") print chr(ord(S[i])+32) chr ord(S[i])+32 ord(S[i]) ord S[i] S i 32 end="" end "" N,K=list(map(int,input().split())) list(map(int,input().split())) N S = list(input()) list(input()) S K=list(map(int,input().split())) list(map(int,input().split())) K
N,K=list(map(int,input().split()))
S = list(input())

for i in range(len(S)):
    if i != K-1:
        print(S[i],end='')
    else:
        print(chr(ord(S[i])+32),end="")
