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

S = eval(input())



ans = ""



for i in range(N) :

    if i == K-1 :

        ans += S[i].lower()

    else :

        ans += S[i]

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

S = eval(input())



print((S[:K-1] + S[K-1].lower() + S[K:]))

N, K = list(map(int, input().split()))
S = eval(input())
ans = ""
for i in range(N):
    if i == K - 1:
        ans += S[i].lower()
    else:
        ans += S[i]
print(ans)

N, K = list(map(int, input().split()))
S = eval(input())
print((S[: K - 1] + S[K - 1].lower() + S[K:]))

-ans = "" -for i in range(N): -    if i == K - 1: -        ans += S[i].lower() -    else: -        ans += S[i] -print(ans) +print((S[: K - 1] + S[K - 1].lower() + S[K:]))