Problem:
 Score : 100 points    Problem Statement You are given a string S of length N consisting of A , B and C , and an integer K which is between 1 and N (inclusive).
Print the string S after lowercasing the K -th character in it.      Constraints  1 ≤ N ≤ 50  1 ≤ K ≤ N  S is a string of length N consisting of A , B and C .         Input Input is given from Standard Input in the following format:  N  K  S       Output Print the string S after lowercasing the K -th character in it.        Sample Input 1 3 1
ABC      Sample Output 1 aBC       Sample Input 2 4 3
CABA      Sample Output 2 CAbA

Solution (Python):
n, k = map(int, input().split())
s = input()

t = ''
for i in range(n):
    if i+1 == k:
        t += s[i].lower()
    else:
        t += s[i]

print(t)

Solution (Python):
n,k=map(int,input().split())
s=input()
a=s[k-1:k].lower()
ans=s[:k-1]+a+s[k:]
print(ans)

Solution (Python):
get = input().split()
N = int(get[0])
K = int(get[1])
st = input()
S =[]
ans = ""
for i in range(N):
    S.append(st[i])
if S[K - 1].isupper():
    S[K - 1] = S[K - 1].lower()
else:
    S[K - 1] = S[K - 1].upper()
for i in range(N):
    ans += S[i]
print(ans)

Solution (Python):
n,k = map(int, input().split())
s = str(input()) 

print(s[:k-1]+s[k-1].lower()+s[k:])

Solution (Python):
n, k = map(int, input().split())
s = str(input())
print(s[:k-1]+s[k-1].lower()+s[k:])

Solution (Python):
n,k = map(int,input().split())
s = list(input())
s[k-1] = s[k-1].lower()
s ="".join(s)
print(s)

Solution (Python):

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

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

Solution (Python):
N,K=[int(x) for x in input().split()]
S=input()
print(S[:K-1]+S[K-1].lower()+S[K:])

Solution (Python):
a,b=map(int, input().split())
n=input()

n=list(n)
n[b-1]=n[b-1].lower()
n="".join(n)
print(n)

Solution (Python):
N, K = map(int, input().split())
S = list(input())
S[K -1] = S[K - 1].lower()
print(''.join(S))

Solution (Python):



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







word = ''




for i in range(len(S)):
    
    if i == K - 1:
        word += S[i].lower()
    else:
        word += S[i]


print(word)

Solution (Python):
N, K = (int(i) for i in input().split())
S = list(input())
K -= 1
x = S.pop(K)

if x == 'A':
  x = 'a'
elif x == 'B':
  x = 'b'
else:
  x = 'c'
S.insert(K, x)
ans = ''
for i in S:
  ans += i
print(ans)

Solution (Python):
n, k = map(int, input().split())
s = input()
print(s[:k-1] + s[k-1].lower() + s[k:])

Solution (Python):
n, k = map(int, input().split())
k -= 1
s = input()
res = s[:k] + s[k].lower() + s[k + 1:]
print(res)

Solution (Python):
x,y = map(int,input().split())	
s=input()	
print(s[:y-1] + s[y-1].lower() + s[y:])

Solution (Python):
M = input().split()
S = input()
S1 = S[:int(M[1])-1] + S[int(M[1])-1].lower() + S[int(M[1]):]
print(S1)

Solution (Python):
N,K=(int(x) for x in input().split())
S=list(input())
S[K-1] = S[K-1].lower()
print(''.join(S))

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

S[K-1] = S[K-1].lower()
print(''.join(S))

Solution (Python):
n,k=list(map(int,input().split()))
s=str(input())

y=s[:k-1]+s[k-1].lower()+s[k:]

print(y)

Solution (Python):
n,k=map(int,input().split())
s=input()
s1=[0 for i in range(n)]
for i in range(n):
    if i==(k-1):
        s1[i]=s[i].lower()
    else:
        s1[i]=s[i]
retu="".join(s1)
print(retu)

Solution (Python):

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

i = k-1
print(s[:i] + s[i].lower() + s[i+1:])

Solution (Python):

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

s[k-1] = s[k-1].lower()
print(''.join(s))

Solution (Python):


import os
import sys

N, K = map(lambda x: int(x), input().split(" "))
S = input()

S = S[0:K-1] + S[K-1].lower() + S[K:len(S)]

print(S)

Solution (Python):
N, K = map(int, input().split())
S = input()
str_list = list(S)
str_list[K-1] = str_list[K-1].lower()
S = "".join(str_list)
print(S)

Solution (Python):
N, K = map(int, input().rstrip().split())
S = [x for x in input().rstrip()]

S[K-1] = S[K-1].lower()
print("".join(S))

Solution (Python):
n, k = map(int, input().split())
s = input()
ans = s[:k - 1] + s[k - 1 : k].lower() + s[k:]
print(ans)

Solution (Python):
N, K = [int(i) for i in input().split()]
S = input()
S = S[:K-1] + S[K-1].lower() + S[K:]
print(S)

Solution (Python):
def main():
    n, k = map(int, input().split())
    s = input()
    print(s[: k - 1] + s[k - 1].lower() + s[k:])


if __name__ == "__main__":
    main()

Solution (Python):
N, K = map(int,input().split())
S = [i for i in input()]
S[K-1] = S[K-1].lower()
print("".join(S))

Solution (Python):
n,k = map(int,input().split())
s = list(input())
s[k-1] = s[k-1].lower()
print("".join(s))

Solution (Python):
n, k = [int(e) for e in input().split()]
s = input()
print(s[:k - 1] + s[k - 1].lower() + s[k:])

Solution (Python):
N, K   = map(int, input().split())
S      = input()

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

Solution (Python):
n, k = map(int, input().split())
str = input()

s = list(str)

s[k-1] = s[k-1].lower()

result = ''.join(s)

print( result )

Solution (Python):

n,k = [int(x) for x in input().split()]
str = input()
print(str[0:k-1]+str[k-1].lower()+str[k:])

Solution (Python):
N,K=map(int,input().split())
S=str(input())
X=S[K-1]
print(S[0:K-1]+X.lower()+S[K:])

Solution (Python):
N,K=map(int,input().split())
S=str(input())
X=S[K-1]
print(S[0:K-1]+X.lower()+S[K:])

Solution (Python):
n, k = [int(_) for _ in input().split()]
s = input()

ans = []
for i in range(len(s)):
    if i == k-1:
        ans.append(s[i].lower())
    else:
        ans.append(s[i])

print("".join(ans))

Solution (Python):
N,K=map(int,input().split())
S=list(input())
S[K-1]=S[K-1].lower()
print("".join(S))

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

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

S[K - 1] = S[K - 1].lower()
print(''.join(S))

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

Solution (Python):
N,K = map(int,input().split())
s = list(input())
s[K-1] = s[K-1].lower()

print("".join(s))

Solution (Python):
n,k=map(int,input().split())
s=input()

res=''
for i in range(n):
	if i==k-1:
		res=res+s[i].lower()
	else:
		res=res+s[i]
print(res)

Solution (Python):
n, k = map(int, input().split())
s = input()

print(s[:k-1]+s[k-1].lower()+s[k:])

Solution (Python):
n,k=map(int,input().split())
s=list(input())
r=""
for i in range(n):
  r = r + (s[i] if i+1!=k else s[i].lower())
print(r)

Solution (Python):
N,K = map(int, input().strip().split(' '))
S = input().strip()

print(''.join(c.lower() if i+1 == K else c for i,c in enumerate(S)))

Solution (Python):
T = {'A': 'a', 'B': 'b', 'C': 'c'}

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

print(S[:K - 1] + T[S[K - 1]] + S[K:])

Solution (Python):
n, k = list(map(int, input().split()))
s = input().split()[0]
new_s = list(s)

new_s[k-1] = new_s[k-1].lower()
new_s = ''.join(new_s)
print(new_s)

Solution (Python):
N, K = [int(item) for item in input().split()]
S = input()

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

Solution (Python):
N,K = list(map(int, input().split()))
A = input()

Alist = list(A)
C = Alist[K-1]
c = C.lower()
Alist[K-1] = c
print(''.join(Alist))

Solution (Python):
N,K=map(int, input().split())
S=list(input())
S[K-1]=S[K-1].lower()
print("".join(S))

Solution (Python):
n,k=map(int,input().split())
s=list(input())
s[k-1] = s[k-1].lower()
z = ''
for i in range(n):
    z +=s[i]
print(z)

Solution (Python):
x,y = map(int,input().split())
z = list(input())
z[y-1]= z[y-1].lower()
print("".join(z))

Solution (Python):
def main():
    N, K = list(map(int, input().split()))
    S = input()
    ans = []
    for i in range(len(S)):
        if (i == K-1):
            ans.append(S[i].lower())
        else:
            ans.append(S[i])

    print("".join(ans))

main()

Solution (Python):
N, K = map(int,input().split())
S = list(input())
s = S[K-1].lower()
S[K-1] = s
print("".join(S))

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

Solution (Python):
n,k = map(int,input().split())
s = list(input())
if s[k-1]=='A':
    s[k-1]="a"
if s[k-1]=='B':
    s[k-1]='b'
if s[k-1]=='C':
    s[k-1]='c'
print(''.join(s))

Solution (Python):
n,k=map(int,input().split())
s=list(input())
s[k-1]=s[k-1].lower()
print("".join(s))

Solution (Python):
n,k=map(int,input().split())
s=list(input())
s[k-1]=s[k-1].lower()
print("".join(s))

Solution (Python):
N, K = map(int, input().split())
S = input()
a = S[K-1].lower()
A = S[0:K-1] + a + S[K:]
print(A)

Solution (Python):
N,K = map(int,input().split())
S = list(input())
ans = ''
if S[K-1] == 'A':
  S[K-1] = 'a'
elif S[K-1] == 'B':
  S[K-1] = 'b'
else:
  S[K-1] = 'c'
for i in range(N):
  ans += S[i]
print(ans)

Solution (Python):
i = input().split(" ")
l = [int(j) for j in i]
n = l[0]
k = l[1]
s = input()
old_letter = s[k-1]
new_letter = old_letter.lower()
print(s[:k-1]+new_letter+s[k:])

Solution (Python):
n,k = map(int,input().split())
s = str(input())
ans = ''
for i in range(len(s)):
  if i == k-1:
    ans = ans + s[i].lower()
  else:
    ans = ans + s[i]
print (ans)

Solution (Python):
a, b = map(int, input().split())
c = input()
d = ""
for i in range(len(c)):
    if i == (b - 1):
        d += c[i].lower()
    else:
        d += c[i]
print(d)

Solution (Python):

n,k=map(int,input().split())
s=input()
k=k-1
s = s[:k]+str(s[k]).lower()+s[k+1:]
print(s)

Solution (Python):
n,k= map(int,input().split())
s=input()
a=""




for i in range(k-1):
  a=a+s[i]

a=a+s[k-1].lower()

for i in range(n-k):
  a=a+s[i+k]
print(a)

Solution (Python):
n, k = list(map(int, input().split()))
s = list(input())
s[k-1] = s[k-1].lower()
print("".join(s))

Solution (Python):
nk = [int(i) for i in input().split()]
n = nk[0]
k = nk[1]
s = input()
if s[k-1] == 'A' :
    print(s[:k-1] + 'a' + s[k:])
elif s[k-1] == 'B':
    print(s[:k-1] + 'b' + s[k:])
else:
    print(s[:k-1] + 'c' + s[k:])

Solution (Python):
n,k = map(int, input().split())
s = input()
print(s[:k-1] + s[k-1].lower() + s[k:])

Solution (Python):
N, K = map(int, input().split())
S = input()
S2 = S[0:K-1]+S[K-1].lower()+S[K:N]
print(S2)

Solution (Python):
N,K = map(int,input().split())
S = list(input())
if S[K-1] == 'A':
    S[K-1] = 'a'
elif S[K-1] == 'B':
    S[K-1] = 'b'
else:
    S[K-1] = 'c'
print(''.join(S))

Solution (Python):
N, K = map(int, input().split())

S = input()

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

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

Solution (Python):
n,k=map(int,input().split())
s=list(input())
s[k-1]=s[k-1].lower()
print(''.join(s))

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

convert_dict = {'A': 'a', 'B': 'b', 'C': 'c'}

ans = ''
for i, s in enumerate(S):
    if i == K-1:
       ans += convert_dict[s] 
    else:
        ans += s

print(ans)

Solution (Python):
n,k = map(int,input().split())
s = input()
if s[k-1] == "A":
    if k != 1 or k != n:
        print(s[:k-1] + "a" + s[k:])
    elif k == 1:
        print("a" + s[1:])
    elif k == n:
        print(s[:n-1] + "a")
elif s[k-1] == "B":
    if k != 1 or k != n:
        print(s[:k-1] + "b" + s[k:])
    elif k == 1:
        print("b" + s[1:])
    elif k == n:
        print(s[:n-1] + "b")
elif s[k-1] == "C":
    if k != 1 or k != n:
        print(s[:k-1] + "c" + s[k:])
    elif k == 1:
        print("c" + s[1:])
    elif k == n:
        print(s[:n-1] + "c")

Solution (Python):
n,k = map(int, input().split())
s = input()

s=list(s)
s[k-1] = s[k-1].lower()
print("".join(s))

Solution (Python):
N,K = map(int,input().split())
S = input()
a = S[K-1].lower()

if K == 1:
    print(a + S[K:])

else:
    print(S[:K-1] + a + S[K:])

Solution (Python):
N,K = map(int,input().split())
S = input()
a = S[K-1].lower()

if K == 1:
    print(a + S[K:])

elif K == 2:
    print(S[0] + a + S[K:])
else:
    print(S[:K-1] + a + S[K:])

Solution (Python):
N, K = list(map(int, input().split()))
S = input()
s=[]
for i in S:
	s.append(i)
x = s[K - 1]
if x == 'A':
	s[K - 1] = 'a'
if x == 'B':
	s[K - 1] = 'b'
if x == 'C':
	s[K - 1] = 'c'

S = "".join(s)
print(S)

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

s[k-1] = s[k-1].lower()
print(''.join(s))

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

Solution (Python):
a, b = map(int, input().split())
s = input()

print(s[:b-1] + s[b-1].lower() + s[b:])

Solution (Python):
n, k = map(int,input().split())
S = input()
S = S[:k-1] + S[k-1].lower() + S[k:]
print(S)

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

Solution (Python):
n, k = (int(i) for i in input().split())  
s = input()
s_ = s[:k-1] + s[k-1].lower() + s[k:]
print(s_)

Solution (Python):
N, K = map(int, input().split())
s = input()

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

Solution (Python):
N,K = (int(x) for x in input().split())
S = input()

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

print(ans)

Solution (Python):
n,k = map(int,input().split())
s = input()
new= s[:k-1] + s[k-1].lower() + s[k:]
print(new)

Solution (Python):
a, b = map(int, input().split())

s = input()

arr = list(s)

arr[b - 1] = arr[b - 1].lower()

print("".join(arr))

Solution (Python):
n, k = map(int, input().split())
s = input()

ans = ""

for i in range(n):
    if i + 1 == k:
        ans += s[i].lower()
    else:
        ans += s[i]

print(ans)

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

s[k-1] = s[k-1].lower()

for i in range(n):
    print(s[i], end="")

Solution (Python):
N,K = list(map(int,input().split()))
S = [input() for i in range(1)][0]
S = list(S)
S[K-1] = S[K-1].lower()
print("".join(S))

Solution (Python):
n,k = map(int,input().split())
s = input()
 
if s[k-1] == "A":
  s=s[0:k-1]+"a"+s[k:n]
elif s[k-1] == "B":
  s=s[0:k-1]+"b"+s[k:n]
else:
  s=s[0:k-1]+"c"+s[k:n]
print(s)

Solution (Python):
n, k = map(int, input().split())
s = input()
print(s[:k-1] + s[k-1].lower() + s[k:])

Solution (Python):
a, b = map(int, input().split())
s = list(input())
s[b - 1] = s[b - 1].lower()
S = str()
for i in range(a):
  S += s[i]
print(S)

Solution (Python):
n, k = map(int, input().split())
s = list(input())
s[k-1] = s[k-1].lower()
print("".join(s))

Solution (Python):
n,k = map(int,input().split())
s = list(input())
for i,char in enumerate(s):
    if i==k-1:
        s[i] = char.lower()

print("".join(s))

Solution (Python):
n, k = map(int, input().split())
s = input()
for i in range(n):
    if i+1 == k:
        print(s[i].lower(), end="")
    else:
        print(s[i], end="")
print()

Solution (Python):
n, k = map(int, input().split())
s = input()
for i in range(n):
    if (i+1) == k:
        print(s[i].lower(), end="")
    else:
        print(s[i], end="")
print("")

Solution (Python):
n, k = map(int, input().split())
s = input()

print(s[:k-1] + s[k-1].lower() + s[k:])

Solution (Python):
N, K = map(int, input().split())

S = list(input())

S[K-1] = S[K-1].lower()

s_new = ""
for i in range(N):
  s_new += S[i]
    
print(s_new)

Solution (Python):
N,K = map(int,input().split())
S = input()

letters = list(S)
letters[K-1] = letters[K-1].lower()

new_S = ""

for letter in letters:
  new_S += letter
  
print(new_S)

Solution (Python):
n, k = map(int, input().split())
s = input()
ans = ""
if k-1 == 0:
    ans += s[k-1].lower()
    ans += s[k:]
elif k-1 == n-1:
    ans += s[:k-1]
    ans += s[k-1].lower()
else:
    ans += s[:k-1]
    ans += s[k-1].lower()
    ans += s[k:]

print(ans)

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

if s[k-1] == 'A':
    s[k-1] = 'a'
elif s[k-1] == 'B':
    s[k-1] = 'b'
elif s[k-1] == 'C':
    s[k-1] = 'c'

print(''.join(s))

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

Solution (Python):
l = list(map(int,input().split()))
N = l[0]
K = l[1] 
S = input()
list_S = list(S)
if list_S[K-1] == 'A':
    list_S[K-1] = 'a'
elif list_S[K-1] == 'B':
    list_S[K-1] = 'b'
if list_S[K-1] == 'C':
    list_S[K-1] = 'c'
L = ''.join(list_S)
print(L)

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

Solution (Python):
N, K = (int(a)for a in input().split())
S = input()
T = S[K-1].lower()

print(S[:K-1]+T+S[K:])

Solution (Python):
n,k = map(int,input().split())

s = input()

s = s[:k-1] + s[k-1].lower() + s[k:]
print(s)

Solution (Python):
n,k = map(int,input().split())
s = input()

s = s[:k-1] + s[k-1].lower() + s[k:]
print(s)

Solution (Python):

N, K = map(int,input().split())
S = list(str(input()))
S[K-1] = S[K-1].lower()
s = str()
for i in range(N):
    s = s + S[i]
print(s)

Solution (Python):
a, b = map(int, input().split())
c = input()
d = ""
for i in range(a):
    if i == b-1:
        d += c[i].lower()
    else:
        d += c[i]
print(d)

Solution (Python):
N, K = map(int, input().split())
S = input()

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

Solution (Python):
n, k = list(map(int, input().split()))
s = input()
print(s[: k - 1] + s[k - 1].lower() + s[k: ])

Solution (Python):
N,K=list(map(int,input().split()))
S=list(input())
if S[K-1]=='A':
    S[K-1]="a"
if S[K-1]=='B':
    S[K-1]='b'
if S[K-1]=='C':
    S[K-1]='c'
print(''.join(S))

Solution (Python):
n,k=map(int,input().split())
s=input()
print(s[:k-1]+s[k-1].lower()+s[k:])

Solution (Python):
N, K = map(int, input().split())
S = input()
ans = S[:K-1]+chr(ord(S[K-1])+32)
if K != N:
	ans = ans + S[K:]
print(ans)

Solution (Python):
import sys
from collections import deque

sys.setrecursionlimit(4100000)


def inputs(num_of_input):
    ins = [input() for i in range(num_of_input)]
    return ins


def solve(inputs):
    [N, K] = string_to_int(inputs[0])
    new_str = ""
    for i, c in enumerate(inputs[1]):
        if i == K-1:
            new_str += c.lower()
        else:
            new_str += c
    return new_str


def string_to_int(string):
    return list(map(lambda x: int(x), string.split()))


if __name__ == "__main__":
    ret = solve(inputs(2))
    print(ret)

Solution (Python):
n, k = map(int,input().split())

p = input()

print(p[:k-1] + p[k-1].lower() + p[k:])

Solution (Python):
n, k = map(int, input().split())
s = input()
print(s[:k - 1] + s[k - 1].lower() + s[k:])

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

Solution (Python):
a, b = map(int, input().split())
c = input()
d = ""
for i in range(len(c)):
    if i + 1 == b:
        d += c[i].lower()
    else:
        d += c[i]
print(d)

Solution (Python):
N,K = map(int,input().split())
S = input()

tmp = list(S)
tmp[K-1] = tmp[K-1].lower()
print(''.join(tmp))

Solution (Python):
n,k = map(int,input().split())
s = input()
c = list(s)
c[k-1] = c[k-1].lower()

for i in c:
    print(i,end='')

Solution (Python):
n,k = map(int,input().split())
s = input()
c = list(s)
c[k-1] = c[k-1].lower()

for i in c:
    print(i,end='')

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

if s[k-1] == 'A':
    s[k-1] = 'a'
elif s[k-1] == 'B':
    s[k-1] = 'b'
else:
    s[k-1] = 'c'

print(''.join(s))

Solution (Python):
n,k=map(int,input().split())
s=str(input())
s=list(s)
s[k-1]=s[k-1].lower()
s="".join(s)
print(s)

Solution (Python):
n, k = map(int, input().split(' '))
s = input()
for i in range(0, n):
    print(s[i].lower(), end="") if i == k - 1 else print(s[i], end="")

Solution (Python):
n,m = map(int,input().split())
s = str(input())
print(s[:m-1]+chr(ord(s[m-1])-ord("A")+ord("a"))+s[m:])

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



if S[K-1] == "A":
    S[K-1] = "a"
if S[K-1] == "B":
    S[K-1] = "b"
if S[K-1] == "C":
    S[K-1] = "c"

print(''.join(S))

Solution (Python):
N, K = map( int, input().split() )
S = input()
result = ""
for i in range(len(S)):
    if i == (K-1):
        result += S[i].lower()
    else:
        result += S[i]

print(result)

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

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

Solution (Python):
N, K = map(int, input().split())
S = list(input())
S[K-1] = S[K-1].lower()
print("".join(S))

Solution (Python):
n,k=map(int,input().split())
s=input()
print(s[:k-1]+s[k-1].lower()+s[k:])

Solution (Python):
N, K = map(int, input().split())
A = input()

if K < len(A):
    ans = A[:K-1] + A[K-1].lower() + A[K:]
else:
    ans = A[:K-1] + A[K-1].lower()

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

Solution (Python):
N, K = map(int, input().split())
A = input()

if K < len(A):
    ans = A[:K-1] + A[K-1].lower() + A[K:]
else:
    ans = A[:K-1] + A[K-1].lower()
print(ans)

Solution (Python):
n,k = map(int,input().split())
s=input()
l=s[k-1].lower()
print(s[:k-1]+l+s[k:])

Solution (Python):
_,k=map(int,input().split())
s=input()
print(s[:k-1]+s[k-1].lower()+s[k:])

Solution (Python):
N, K = map(int, input().split())
S = input()

s = list(S)
s[K-1] = s[K-1].lower()
print(''.join(s))

Solution (Python):


n, k = map(int, input().split())
stringS = input()

print(stringS[:k-1] + stringS[k-1].lower() + stringS[k:])

Solution (Python):


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

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

print(ans)

Solution (Python):


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

S[K-1] = S[K-1].lower()

ans = "".join(S)

print(ans)

Solution (Python):
n, k = map(int, input().split())
s = input()

print(s[:k-1] + s[k-1].lower() + s[k:])

Solution (Python):
n,k = map(int,input().split())

s = list(input())
s[k-1] = s[k-1].lower()

print(''.join(s))

Solution (Python):



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


ans = ''
for i in range(len(S)):
    ans += S[i] if i != K - 1 else S[i].lower()


print(ans)

Solution (Python):
def main():
    n, k = map(int,input().split())
    s = list(input())

    s[k-1] = s[k-1].lower()
    ans = []
    ans = "".join(map(str,s))
    print(ans)

main()

Solution (Python):
N, K = map(int, input().split())
S = list(input())
S[K-1] = S[K-1].lower()
print("".join(S))

Solution (Python):
n,k=map(int,input().split())
s=list(input())
s[k-1]=s[k-1].lower()
ss="".join(s)
print(ss)

Solution (Python):
n, k = map(int, input().split())

s = list(input())


for i in range(n):
    if i != k - 1:
        print(s[i], end = "")
    else:
        print(s[i].lower(), end = "")

print()

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

Solution (Python):
n,k = map(int,input().split())
s = input()
if s[k-1:k] == 'A':
    s = s[0:k-1] +'a'+s[k::]
elif s[k-1:k] == 'B':
    s = s[0:k-1] +'b'+s[k::]
else:
    s = s[0:k-1] +'c'+s[k::]
print(s)

Solution (Python):
N,K = map(int,input().split())
S = list(input())
if S[K-1]=="A":
    S[K-1]="a"
elif S[K-1]=="B":
    S[K-1]="b"
else:
    S[K-1]="c"
print(''.join(S))

Solution (Python):
def main():
    _, K = map(int, input().split())
    S = input()
    k = K - 1

    print(S[:k] + S[k].lower() + S[k+1:])


main()

Solution (Python):
a, b = map(int,input().split())
s = input()
print(s[:b-1] + s[b-1].lower() + s[b:])

Solution (Python):
N, M = map(int, input().split())
s = input()
ans = ''
for i in range(N):
  if i == M-1:
    ans += s[i].lower()
  else:
    ans += s[i]
print(ans)

Solution (Python):
N, K= [int(_) for _ in input().split()]
S = input()
S = S[:K-1]+S[K-1].lower() +S[K:]
print(S)

Solution (Python):
n,k = map(int,input().split())
s = input()
new= s[:k-1] + s[k-1].lower() + s[k:]
print(new)

Solution (Python):
N, change = map(int, input().split())
string = list(input())
string[change-1] = string[change-1].lower()
print(''.join(string))

Solution (Python):
a, b = map(int, input().split())
c = input()
c = c[:b-1] + c[b-1].lower() + c[b:]
print(c)

Solution (Python):
n,k = map(int,input().split())
s = list(input())
if s[k-1] == "A":
	s[k-1]="a"
elif s[k-1]=="B":
	s[k-1]="b"
else:
	s[k-1]="c"
print("".join(s))

Solution (Python):
def main():
  n, k = map(int, input().split())
  s = list(input())
  
  s[k-1] = s[k-1].lower()
  
  print("".join(s))
  
main()

Solution (Python):
N,K = map(int, input().split())
S = input()
newS = ''
for i in range(N):
  if i == K-1:
    if S[i] == 'A':
      newS += 'a'
    if S[i] == 'B':
      newS += 'b'
    if S[i] == 'C':
      newS += 'c'
  else:
    newS += '{}'.format(S[i])

print(newS)

Solution (Python):
n, k = map(int, input().split())
string = input()

for i in range(len(string)):
    if i == k - 1:
        print(chr(ord(string[i]) + 32), end="")
    else:
        print(string[i], end="")
print("")

Solution (Python):


n, k = map(int, input().split())
s = input()
print(s[:k - 1] + s[k - 1].lower() + s[k:])

Solution (Python):
def resolve():
    n,k = map(int,input().split())
    s = input().strip()
    s = list(s)
    if s[k-1]=='A':
        s[k-1]='a'
    elif s[k-1]=='B':
        s[k-1]='b'
    else:
        s[k-1]='c'
    s = ''.join(s)
    print(s)

if __name__ == "__main__":
    resolve()

Solution (Python):
n, k = map(int,input().split())
s = input().split()

li = []

for i in range(n):
    if k-1 == i:
        li.append(s[0][i].lower())
    else:
        li.append(s[0][i])

print(''.join(li))

Solution (Python):
n, k = map(int,input().split())
s = input().split()

li = []

for i in range(n):
    if k-1 == i:
        li.append(s[0][i].lower())
    else:
        li.append(s[0][i])

print(''.join(li))

Solution (Python):
n, k = input().split(" ")
s=input()
k = int(k)-1

sk = s[k].lower()
s = s[:k]+sk+s[k+1:]
print(s)

Solution (Python):
n, k = list(map(int, input().split()))
s = list(input())
ans = ""
for i in range(n):
    if i == k - 1:
        ans += s[i].lower()
    else:
        ans += s[i]
print(ans)

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

Solution (Python):
_, K = map(int, input().split())
S = input()

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

Solution (Python):
n, k = map(int,input().split())
s = list(input())
s[k-1] = s[k-1].lower()
print(''.join(s))

Solution (Python):
N, K = map(int,input().split())
S = list(input())
S[K-1] = str.lower(S[K-1])
print("".join(S))

Solution (Python):
n,k = map(int,input().split())
s = list(input())
s[k-1]= str.lower(s[k-1])
print("".join(s))

Solution (Python):
N, K = map(int, input().split())
S = list(input())
S[K-1]= S[K-1].lower()
print(''.join(S))

Solution (Python):
n, k = map(int, input().split())
s = input()
l = list(s)
l[k-1] = l[k-1].lower()
print("".join(l))

Solution (Python):
a, b = [int(x) for x in input().split()]
lst = list(input())
lst[b - 1] = lst[b - 1].lower()
print(''.join(lst))

Solution (Python):
N,K=map(int,input().split())
S=input()
s=list(S)
s[K-1]=s[K-1].lower()
print(','.join(s).replace(',',''))

Solution (Python):
n,k = map(int,input().split())
s = input()
t=''
for i in range(n):
    if i==(k-1):
        t+=s[i].lower()
    else:
        t+=s[i]
print(t)

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

Solution (Python):
n,k=map(int,input().split())
strs=list(input())
strs[k-1]=strs[k-1].lower()
print(*strs, sep='')

Solution (Python):
n, k = map(int, input().split())
s  =  str(input())
                 
s = s[:k-1] + s[k-1].lower() + s[k:]       
print(s)

Solution (Python):
n,k = map(int , input().split())
s = input()
k-=1
print(s[:k]+s[k].lower()+s[k+1:])

Solution (Python):
a, b = map(int, input().split())
s = input()
ans = ''
for i in range(len(s)):
    if i + 1 == b:
        ans += s[i].lower()
    else:
        ans += s[i]
print(ans)

Solution (Python):

N,K = map(int,input().split())
S = list(input())
S[K-1] = S[K-1].lower()
S="".join(S)
print(S)

Solution (Python):
n,k=map(int,input().split())
s=input()
ans=[]
for i in range(n):
    if i==k-1:
        ans.append(s[i].lower())
    else:
        ans.append(s[i])

for j in range(n):
    print(ans[j], end="")

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

if s[k-1]=='A':
    s[k-1]='a'
elif s[k-1]=='B':
    s[k-1]='b'
elif s[k-1]=='C':
    s[k-1]='c'

print(''.join(s))

Solution (Python):
n, k = map(int, input().split())
s = input()

print(s[:k-1] + s[k-1].lower() + s[k:n])

Solution (Python):
N,k=map(int,input().split())
S=input()
print(S[:k-1] + S[k-1].lower() + S[k:])

Solution (Python):
n, k = map(int, input().split())
s = list(map(str, input()))
s[k - 1] = s[k -1].lower()
print("".join(s))

Solution (Python):
N_mojiretsu, K_number = map(int, input().split())
L_mojiretsu = list(input())
L_mojiretsu[K_number-1] = L_mojiretsu[K_number-1].lower()
print(''.join(L_mojiretsu))

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

Solution (Python):

from sys import stdin




def _li(): return list(map(int, stdin.readline().split()))
def _li_(): return list(map(lambda x: int(x)-1, stdin.readline().split()))
def _lf(): return list(map(float, stdin.readline().split()))
def _ls(): return stdin.readline().split()
def _i(): return int(stdin.readline())
def _f(): return float(stdin.readline())
def _s(): return stdin.readline()[:-1]


N, K = _li()
S = _s()

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

Solution (Python):
from sys import stdin
from collections import defaultdict

N, K = [int(x) for x in stdin.readline().rstrip().split()]

S = stdin.readline().rstrip()


if K == 1:
    S3 = list(S[0].lower())
else:
    S3 = list(S[0])
for i in range(1,N):
  if i+1 == K:
    S3.append(S[i].lower())
  else:
    S3.append(S[i])

S4 = ''.join(S3)
print(S4)

Solution (Python):
from sys import stdin
from collections import defaultdict

N, K = [int(x) for x in stdin.readline().rstrip().split()]

S = stdin.readline().rstrip().split()
S2 = ''.join(S)

if K == 1:
    S3 = list(S2[0].lower())
else:
    S3 = list(S2[0])
for i in range(1,N):
  if i+1 == K:
    S3.append(S2[i].lower())
  else:
    S3.append(S2[i])

S4 = ''.join(S3)
print(S4)

Solution (Python):
n,k = map(int,input().split())
s = list(input())
s[k - 1] = s[k - 1].lower()
print("".join(s))

Solution (Python):
N, K = map(int, input().split())
S = list(input())
S[K-1] = str.swapcase(S[K-1])
print(''.join(S))

Solution (Python):
n,k = input().split()
s = list(input())
s[int(k)-1] = s[int(k)-1].lower()
print(''.join(s))

Solution (Python):

import bisect
from collections import defaultdict

def main():
    N, K = map(int, input().split())
    S = list(input().strip())

    S[K-1] = S[K-1].lower()
    print("".join(S))


if __name__ == '__main__':
    main()

Solution (Python):
N,K=map(int, input().split())
S=list(input())
S[K-1]=S[K-1].lower()
print("".join(S))

Solution (Python):
N,K = map(int, input().split())
S = list(input())
target = S[K-1]
if target == "A":
    S[K-1] = "a"
elif target == "B":
    S[K-1] = "b"
else:
    S[K-1] = "c"

for str in S:
    print(str, end="")

Solution (Python):
x,y = map(int,input().split())
s=list(input())
s[y-1]=s[y-1].lower()
print(''.join(s))

Solution (Python):
a, b = map(int, input().split())  
str = list(input())

if str[b-1] <= 'z' and str[b-1] >='a':
    str[b-1] = str[b-1].upper()
else:
    str[b-1] = str[b-1].lower()

for s in str:
    print(s, end="")

Solution (Python):
a, b = map(int, input().split())  
str = list(input())

if str[b-1] <= 'z' and str[b-1] >='a':
    str[b-1] = str[b-1].upper()
else:
    str[b-1] = str[b-1].lower()

for s in str:
    print(s, end="")

Solution (Python):
n,k=map(int,input().split())
X=input()
print(X[:k-1]+X[k-1].lower()+X[k:])

Solution (Python):
N, K = map(int, input().split(" "))
S = str(input())

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