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):
"""
author : halo2halo
date : 12, Jan, 2020
"""

import sys

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
sys.setrecursionlimit(10 ** 7)

N, K = map(int, readline().split())
S = read().decode('utf8')
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):
n, k = map(int, input().split())
s = input()

a = s[:k-1]
b = s[k-1].lower()
c = s[k:]

print(a + b + c)

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

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

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

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()
s = s[:k-1] + s[k-1].lower() + s[k:]
print(s)

Solution (Python):
n, k = (int(i) for i in 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):
a, b = map(int, input().split())
c = input()
print(c[0:b-1]+c[b-1].lower()+c[b:])

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

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()

for i, s in enumerate(S):
    if i == K - 1:
        print(s.lower(), end="")
    else:
        print(s, end="")

Solution (Python):

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


for i in range(K-1):
    print(S[i], sep = "", end = "")
print(S[K-1].lower(), sep = "", end = "")
for i in range(K, N):
    print(S[i], sep = "", end = "")

Solution (Python):


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

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

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

for i in range(n):
    if i == k - 1:
        print(chr((ord(s[i])+32)), end='')
    else:
        print(s[i], end='')
print()

Solution (Python):
X = [int(i) for i in input().split()]
S = list(input())

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

print(''.join(S))

Solution (Python):
N, K = 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))

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()
if s!=k:
  ans=s[:k-1]+s[k-1].lower()+s[k:]
else:
  ans=s[:k-1]+s[k-1].lower()
print(ans)

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

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

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

Solution (Python):
def main():
    N, K = map(int, input().split(" "))
    S = input()
    if S[K-1] == 'A':
        result = S[:max(K - 1, 0)] + 'a' + S[K:]
    elif S[K-1] == 'B':
        result = S[:max(K - 1, 0)] + 'b' + S[K:]
    else:
        result = S[:max(K - 1, 0)] + 'c' + S[K:]
    print(result)


if __name__ == '__main__':
    main()

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

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()

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

Solution (Python):
x = input()
s = input()

n, k = x.split()
k = int(k)
s = list(s)

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

print("".join(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(*s,sep="")

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

str_list = list(before_str)
str_list[K-1] = str_list[K-1].swapcase()

after_str = ''.join(str_list)

print(after_str)

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):


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

main()

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

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

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

Solution (Python):
INT = lambda: int(input())
INTM = lambda: map(int,input().split())
STRM = lambda: map(str,input().split())
STR = lambda: str(input())
LIST = lambda: list(map(int,input().split()))
LISTS = lambda: list(map(str,input().split()))
def do():
    n,k=INTM()
    s=STR()
    if k>1and k!=n:
        S=s[0:k-1]+s[k-1].lower()+s[k:n]
        print(S)
    elif k==1:
        S=s.capitalize()
        S=S.swapcase()
        print(S)
    else:
        S=s[0:n-1]+s[n-1].lower()
        print(S)
if __name__ == '__main__':
    do()

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

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

pos = 1

for s_i in s:
  if pos == k:
    print(s_i.lower(), end = '')
  else:
    print(s_i, end = '')
  
  pos += 1

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()

K-=1

if S[K]=="A":
   S=[c for c in S]
   S[K]="a"
   print("".join(S))

elif S[K]=="B":
   S=[c for c in S]
   S[K]="b"
   print("".join(S))

else:
   S=[c for c in S]
   S[K]="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 = list(map(int,input().split(" ")))
A = list(input())
A[K-1] = A[K-1].lower()
print("".join(A))

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

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

Solution (Python):
N,K=map(int,input().split())
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 = list(input())
 
S[K-1] = S[K-1].lower()
 
for i in S:
    print(i,end='')

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


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

print(*S,sep="")

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

print(''.join(s))

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

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

output = ''
cnt = 0
for i in S:
    cnt += 1
    if cnt == K:
        output += i.lower()
    else :
        output += i

print(output)

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

print("".join(s))

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

for s in S:
    if count == K:
        s = s.lower()
    out += s
    count += 1
    
print(out)

Solution (Python):
N, K = map(int, input().split())
S = input()
print("".join(s.lower() if i == K else s for i, s in enumerate(S, 1)))

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

small = {'A':'a', 'B':'b', 'C':'c'}
print(S[:K-1] + small[S[K-1]] + S[K:])

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

s = input()

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

print(s_)

Solution (Python):
num = list(map(int,input().split()))
moji = input()
for o in range(num[0]):
	if(o == num[1]-1):
		print(moji[o].lower(),end="")
	else:
		print(moji[o],end="")

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

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):
a,b=map(int,input().split())
s=[i for i in input()]
b-=1
s[b]=s[b].lower()
print("".join(s))

Solution (Python):
N,K = map(int,input().split())
S = list(str(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 = 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]=chr(ord(s[k-1])+32)

print(*s,sep='')

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

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

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

Solution (Python):
N, K = map(int, input().split())
S = list(str(input()))
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[:k-1]+'a'+s[k:]
elif s[k-1]=='B':
  s=s[:k-1]+'b'+s[k:]
else:
  s=s[:k-1]+'c'+s[k:]
print(s)

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())

S = ''

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

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 = map(int, input().split())
S = input()

ans = ""
for i in range(N):
    if i == K-1 and S[i] == "A":
        ans += "a"
    elif i == K-1 and S[i]  == "B":
        ans += "b"
    elif i == K-1 and S[i]  == "C":
        ans += "c"
    else:
        ans += S[i]
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()

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

for i in range(N):
  if K - 1 == i:
    print(m[S[i]], end='')
  else:
    print(S[i], end='')
print()

Solution (Python):
n,k=map(int,input().split())
s=input()
if s[k-1]=='A':
  s=s[:k-1]+'a'+s[k:]
elif s[k-1]=='B':
  s=s[:k-1]+'b'+s[k:]
else:
  s=s[:k-1]+'c'+s[k:]
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 = input()
S_list =list(S)
l ={"A":"a","B":"b","C":"c"}
ans=S_list[K-1]
S_list[K-1]=l[ans]
print("".join(S_list))

Solution (Python):


import sys
import math
from bisect import bisect_right as br
from bisect import bisect_left as bl
sys.setrecursionlimit(1000000)
from heapq import heappush, heappop,heappushpop
from collections import defaultdict
from itertools import accumulate
from collections import Counter
from collections import deque
from operator import itemgetter
from itertools import permutations
mod = 10**9 + 7
inf = float('inf')
def I(): return int(sys.stdin.readline())
def LI(): return list(map(int,sys.stdin.readline().split()))

n,k = LI()
s = input()
s = s[:k-1] + s[k-1].lower() + s[k:]
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 = input()
sk = s[k-1].lower()
print(s[:k-1] + sk + s[k:])

Solution (Python):
N, K = list(map(int, input().split()))
S = list(str(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(*s,sep='')

Solution (Python):
n, k = map(int, input().split())
s = str(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=str(input())
T=""
for i in range(len(S)):
    if i+1 == K:
        T += S[i].lower()
    else:
        T += S[i]
print(T)

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"

ss = "".join(s)

print(ss)

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(n):
    if i == k - 1:
        ans += s[i].lower()
    else:
        ans += s[i]
print(ans)

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

i = 1
result = ""
for val in S:
    if i == K:
        result += val.lower()
    else:
        result += val
    i += 1
print(result)

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=s[:k-1]+s[k-1].lower()+s[k:]
print(l)

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

s[K-1]=chr(ord(s[K-1])+32)
print("".join(s))

Solution (Python):
n, k = map(int, input().split())
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()
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 = list(input())
s[k-1] = s[k-1].lower()
st = "".join(s)
print(st)

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

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

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

Solution (Python):
n, k = [int(x) for x in 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]+chr(ord(s[k-1])-ord("A") +ord("a"))+s[k:])

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

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

print(*s, sep='')

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

Solution (Python):
N,b=map(int,input().split())
S=input()
S=S[:b-1]+S[b-1].lower()+S[b:]
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=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]=="A":
    print(s[:k-1]+"a"+s[k:])

if s[k-1]=="B":
    print(s[:k-1]+"b"+s[k:])

if s[k-1]=="C":
    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 = list(map(int, input().split()))
S = list(input())
c = S[K-1]
S[K-1] = c.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()
s = s[:k-1] + s[k-1].lower() + s[k:]
print(s)

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

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

Solution (Python):

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

change_char = S[K-1]
if change_char == "A":
    S[K-1] = "a"
elif change_char == "B":
    S[K-1] = "b"
else:
    S[K-1] = "c"

print("".join(S))

Solution (Python):
N,K = (int(x) for x in input().split())
S = input()
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)

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 = input()
print(s[:k-1] + s[k-1].lower() + s[k:])

Solution (Python):


data1 = input().rstrip().split()
data2 = input()
n = int(data1[0])
k = int(data1[1])

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

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

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

print(*s, sep="")

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

Solution (Python):
N,K = map(int,input().split())
S = input()
S[K-1].lower()
print(S[:K-1]+ S[K-1].lower() + S[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();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,M = input().strip().split()
K = int(M)
S = input()
if K <= int(N):
  print(S[:K-1]+S[K-1].lower()+S[K:])

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

Solution (Python):
n = input()
s = list(input())

p = int(n.split()[1])

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

print(''.join(s))

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

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

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

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

print(S[:K-1]+S[K-1].swapcase()+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):
p,q=map(int,input().split())
s=input()
a=[]
for i in s:
    a.append(i)
q=q-1
a[q]=chr(ord(a[q])+32)
print(''.join(a))

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

c = s[k-1]
c_lower = chr(ord(c) + 32)



ans = s[:k-1] + c_lower + s[k:] 

print(ans)

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

if S[K-1] == 'A':
  S= S[:K-1] + 'a' + S[K:]
elif S[K-1] == 'B':
  S= S[:K-1] + 'b' + S[K:]
elif S[K-1] == 'C':
  S= S[:K-1] + 'c' + S[K:]

print(S)

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

for i in range(len(S)):
    if i == K - 1:
        if S[i] == "A":
            print("a", end="")
        elif S[i] == "B":
            print("b", end="")
        else:
            print("c", end="")
    else:
        print(S[i],end="")

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

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

print(s[0:k-1] + a + s[k:])

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



s = S[K-1]

s_large = s.lower()


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

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

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

x = ''.join(s)
print(x)

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'

buf = ''
for i in range(N) :
    buf += S[i]
print(buf)

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 = input()
s = s[:k-1] + s[k-1].lower() + s[k:]
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 = [char.lower() if i+1==K else char for i, char in enumerate(input())]

print(''.join(S))

Solution (Python):
N, K = map(int, input().split())
S = [char.lower() if i+1==K else char for i, char in enumerate(input())]

print(''.join(S))

Solution (Python):
N, K = [int(i) for i in input().split()]
S = 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 = list(input())

C2c = {'A':'a', 'B':'b', 'C':'c'}
S[K-1] = C2c[S[K-1]]
print(''.join(S))

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

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

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

Solution (Python):
n,k=map(int,raw_input().split())
s = raw_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, raw_input().split())
s = raw_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()

list_s = list(s)
list_s[k-1] = chr(ord(list_s[k-1]) + ord('a') - ord('A'))

print(''.join(list_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= list(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"


for i in range(N):
    print(S[i], end="")

Solution (Python):

import math
import datetime





N, K = map(int, input().split())
S = str(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:])
elif S[K-1] == "C" :
  print (S[:K-1] + "c" + S[K:])

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 = list(input())

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

print(''.join(s))

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

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

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

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

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

print(''.join(s))

Solution (Python):
cap = list("AaBbCc")

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

no = int(cap.index(s[k-1]))
s[k-1] = cap[no+1]

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

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

Solution (Python):
n,k=map(int, input().split())
s=str(input())
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'
print(''.join(S))

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

moji = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"

a = moji.index(S[K-1])
S[K-1] = moji[(a+26)%52]
print(''.join(S))

Solution (Python):
import sys
input = sys.stdin.readline
def print_ans(N, K, S):
    """Test Case
    >>> print_ans(3, 1, "ABC")
    aBC
    >>> print_ans(4, 3, "CABA")
    CAbA
    """
    tmp = S[K - 1].lower()
    ans = [tmp if i == K - 1 else s for i, s in enumerate(S) ]
    print(''.join(ans))

if __name__ == '__main__':
    N, K = map(int, input().rstrip().split())
    S = input().rstrip()
    print_ans(N, K, 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()
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 = list(input())
if S[K - 1] == "A":
    S[K - 1] = "a"
    print("".join(S))
elif S[K - 1] == "B":
    S[K - 1] = "b"
    print("".join(S))
else:
    S[K - 1] = "c"
    print("".join(S))

Solution (Python):
n,k=map(int,input().split())
s=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):
n,k = map(int,input().split())
s = list(input())
for i in range(k):
  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':
  print(S[:K-1] + 'a' + S[K:])
elif S[K-1] == 'B':
  print(S[:K-1] + 'b' + S[K:])
elif S[K-1] == 'C':
  print(S[:K-1] + 'c' + S[K:])

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

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

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

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

Solution (Python):



def ri():
    return int(input())

def rl():
    return list(input().split())

def rli():
    return list(map(int, input().split()))



def main():
    m = {'A':'a', 'B':'b', 'C':'c'}
    n, k = rli()
    s = list(input())
    s[k-1] = m[s[k-1]]
    print("".join(s))


if __name__ == '__main__':
    main()

Solution (Python):
N, K = list(map(int, input().split()))
S = list(input())
temp = S[K-1].lower()
S[K-1] = temp
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=list(input())
S[K-1]=S[K-1].lower()
print("".join(S))

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

S[K-1] = S[K-1].lower()
ans = str()
for i in S:
    ans += i 
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[:k-1]+s[k-1].lower()+s[k:n])

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 = map(int,input().split())
s = list(input())
s[k-1]=s[k-1].lower()
print("".join(s))

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

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=input()
print(s[:k-1]+s[k-1].lower()+s[k:])

Solution (Python):
n, k = [int(s) for s 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()

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

d={"A":"a","B":"b","C":"c"}

s[k-1]=d[s[k-1]]

print(*s,sep="")

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

Solution (Python):
def examA():
    N, K = LI()
    St = S()
    ans = St[0:(K-1)] + St[(K-1):K].lower() + St[K:]
    print(ans)


import sys
import copy
import bisect
import heapq
from collections import Counter,defaultdict,deque
def I(): return int(sys.stdin.readline())
def LI(): return list(map(int,sys.stdin.readline().split()))
def LS(): return sys.stdin.readline().split()
def S(): return sys.stdin.readline().strip()
mod = 10**9 + 7
inf = float('inf')

examA()

Solution (Python):
N,K=map(int,input().split())
S=list(map(str,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(map(str,S)))

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

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

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

print("".join(cs))

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

Solution (Python):
import sys
sys.setrecursionlimit(10**9)
INF = 10**18


def input():
    return sys.stdin.readline().rstrip()


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 = str(input())


for i in range(n):
    if i != k-1:
        print(s[i], end='')
    else:
        if s[i] == 'A':
            print('a', end='')
        elif s[i] == 'B':
            print('b', end='')
        else:
            print('c', end='')