n, k = list(map(int, input().split()))
s = input()

ans = s[:k-1] + s[k-1].swapcase() + s[k:]

print(ans) 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 = input() s input() input ans = s[:k-1] + s[k-1].swapcase() + s[k:] ans s[:k-1] + s[k-1].swapcase() + s[k:] s[:k-1] + s[k-1].swapcase() s[:k-1] s :k-1 k-1 k 1 s[k-1].swapcase() [k-1].swapcase [k-1] s k-1 k 1 swapcase s[k:] s k: k print(ans) print ans n, k = list(map(int, input().split())) list(map(int, input().split())) n s = input() input() s ans = s[:k-1] + s[k-1].swapcase() + s[k:] s[:k-1] + s[k-1].swapcase() + s[k:] ans k = list(map(int, input().split())) list(map(int, input().split())) k
n, k = list(map(int, input().split()))
s = input()

ans = s[:k-1] + s[k-1].swapcase() + s[k:]

print(ans)