N, K = map(int, input().split())
S = str(input())
ans = ''
for i in range(N):
    if i == K-1:
        temp = S[i].lower()
        ans += temp
    else:
        ans += S[i]

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

print(ans)