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



Sample input:
3 1
ABC


Sample output:
aBC

Submission status: Accepted

Solution code:
n, k = map(int, input().split())
word = input()
res = ''
for index, w in enumerate(word):
	if index == k-1:
		w = w.lower()
	res += w
print(res)

Submission status: Accepted

Solution code:
n, k = map(int, input().split())
s = input()
ans = ""

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

print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
N, K = map(int, input().split())
S = list(input())
#Pythonの文字列 = immutable(変更不能)

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

print(''.join(S))

Submission status: Accepted

Solution code:
N, K = map(int, input().split())
S = list(input())
#Pythonの文字列 = immutable(変更不能)

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

print(''.join(S[:K - 1] + [s] + S[K:]))

Submission status: Accepted

Solution code:
n,k=map(int,input().split())
ans = ''
cnt = 0
for a in input():
  cnt += 1
  if cnt == k:
    ans += a.lower()
  else:
    ans += a
print(ans)

Submission status: Accepted

Solution code:
N, K = list(map(int, input().split()))
S = input()
if K == 1:
    print(S[0:1].lower() + S[1:])
elif K == N:
    print(S[0:K - 1] + S[-1].lower())
else:
    print(S[0:K - 1] + S[K - 1:K].lower() + S[K:])

Submission status: Accepted

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

Submission status: Accepted

Solution code:
N,K = map(int, input().split())
S = input()
S = [c for c in S]
S[K-1] = S[K-1].lower()
res = print(''.join(S))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
N, K = map(int, input().split())
S = input()
A = ""

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

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline

import heapq

def main(): 

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

if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
n, k = map(int, input().split())
s = input()
upper = {
    'A': 'a',
    'B': 'b',
    'C': 'c',
}
print(s[:k-1] + upper[s[k-1]] + s[k:])

Submission status: Accepted

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

Submission status: Accepted

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

print(''.join(S))

Submission status: Accepted

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

Submission status: Accepted

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

letters = ''
for i, l in enumerate(input()):
  if i + 1 == k:
    letters += l.lower()
  else:
    letters += l
print(letters)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n,k=map(int,input().split())
S=input()
s_dict={
   'A':'a', 
   'B':'b',
   'C':'c'
   }
ans=''

for i,s in enumerate(S):
    if i!=(k-1):
        ans+=s
    else:
        ans+=s_dict[s]
print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
c=list(input())
c[b-1]=c[b-1].lower()
print(*c,sep="")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

print(''.join(S))

Submission status: Accepted

Solution code:
n, k = map(int, input().split())
s = str(input()).upper()
if 1 <= n <= 50 and 1 <= k <= n == len(s):
    chibi = s[k-1].lower()
    moji = list(s)
    moji[k-1] = chibi
    print("".join(moji))
else:
    print('Invalid value')

Submission status: Accepted

Solution code:
def main():
    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]
    return ans
    
if __name__ == '__main__':
    print(main())

Submission status: Accepted

Solution code:
N,K=map(int,input().split())
S=str(input())
s=S[K-1:K]
s1=S[0:K-1]
s2=S[K:N]
if s=='A':
    ans=s1+'a'+s2
elif s=='B':
    ans=s1+'b'+s2
else:
    ans=s1+'c'+s2
print(ans)

Submission status: Accepted

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

S = input()

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

Submission status: Accepted

Solution code:
#coding:utf-8
n, k = map(int, input().split())
s = input()
print(s[:k-1] + s[k-1].lower() + s[k:])

Submission status: Accepted

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

Submission status: Accepted

Solution code:
x = [int(i) for i in input().split()]
str = input()
str_list = list(str)
for i in range(x[0]):
    if(i==x[1]-1):
        str_list[i] = str_list[i].lower()
    print(str_list[i], end="")

Submission status: Accepted

Solution code:
N,K = map(int,input().split())
S = [s for s in input()]
ans = ""

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

for s in S:
    ans += s 
print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
#!/usr/bin/env python

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

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

if __name__ == '__main__':
    print(main())

Submission status: Accepted

Solution code:
n, k = map(int, input().split())
string = input()
ans = ''
for i, char in enumerate(string):
    if i == (k - 1):
        ans += char.lower()
    else:
        ans += char
print(ans)

Submission status: Accepted

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

print("".join(s))

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
N, K = map(int, input().split())
S = list(input())
S[K - 1] = S[K - 1].lower()
ans = ''

for st in S:
	ans += st

print(ans)

Submission status: Accepted

Solution code:
#### import ####
import sys
import math
from collections import defaultdict

#### 設定 ####
sys.setrecursionlimit(10**7)
def input():
    return sys.stdin.readline()[:-1]

#### 定数 ####
mod = 10**9 + 7

#### 読み込み ####
def I(): return int(input())
def II(): return map(int, input().split())
def III(): return list(map(int, input().split()))
def Line(N):
    read_all = [tuple(map(int, input().split())) for _ in range(N)]
    return map(list,zip(*read_all))

#################

N,K = II()
S = str(input())

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

print(S)

Submission status: Accepted

Solution code:
n,k=[int(i) for i in input().split()]
word=input()
if word[k-1]=="A":
    print(word[:k-1]+"a"+word[k:])
if word[k-1]=="B":
    print(word[:k-1]+"b"+word[k:])
if word[k-1]=="C":
    print(word[:k-1]+"c"+word[k:])

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
# n, k: 数値　s: 文字列　が与えられる
# k文字目を入れ替えよ

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

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

# キーとなる文字　文字列のインデックスは0から
# s[k-1]


# 小文字にする表現がある 下記なら1発
print(s[:k-1] + s[k-1].lower() + s[k:])

# [開始インデックス:終了インデックス] 数値は　より大　と　未満
# print(s[:k-1] + dic.get(s[k-1]) + s[k-1:])

Submission status: Accepted

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

# 小文字にする表現がある 下記なら1発
print(s[:k-1] + s[k-1].lower() + s[k:])

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

for num, i in enumerate(s):
    if num == k-1:
        print(i.lower(), end='')
    else:
        print(i, end='')
print()

Submission status: Accepted

Solution code:
N,K=input().split()
N,K=int(N),int(K)-1
S=input()

#文字列はイミュータブル
'''
if S[K]=="A":
    S[K]="a"
elif S[K]=="B":
    S[K]="b"
else:
    S[K]="c"

print(S)
'''
Slist=list(S)
if S[K]=="A":
    Slist[K]="a"
elif S[K]=="B":
    Slist[K]="b"
else:
    Slist[K]="c"

print("".join(Slist))

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

print(m)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
N,K=map(int,input().split())
S=list(input())
ANS=' '

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

for i in S:
    ANS+=i

print(ANS)

Submission status: Accepted

Solution code:
def solve():
    n, k = map(int, input().split())
    s = input()
    ans = ""
    for i in range(n):
        if k == i + 1:
            ans += s[i].lower()
        else:
            ans += s[i]
    return ans


if __name__ == "__main__":
    print(solve())

Submission status: Accepted

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

Submission status: Accepted

Solution code:
_, K = map(int, input().split())
S=input()
print(S[0:K-1],S[K-1].lower(),S[K:], sep="")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:

inputa = input().split()

inputb = input()


a = int(inputa[0])
b = int(inputa[1])
# c = int(input[2])

inputList = list(inputb)

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

ans = "".join(inputList)

print(ans)

# inputList.sort()
#
# list = [a+b, b+c ,c+a]
#
# ans = min(list)
# print(ans)



# flg = 1
# for i in range(0, len(inputList)-1):
#     if inputList[i] == inputList[i + 1]:
#         flg = 0
#         break
#
# if flg == 0:
#     print("Bad")
# else:
#     print("Good")

Submission status: Accepted

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

Submission status: Accepted

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

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

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

print("")

Submission status: Accepted

Solution code:
temp=list(map(int, input().split()))
S=list(input())
K=int(temp[1]-1)

if S[K]=='A':
  S[K]='a'
elif S[K]=='B':
  S[K]='b'
else:
  S[K]='c'
  
print("".join(S))

Submission status: Accepted

Solution code:
#  Changing a Character
N, K = map(int,input().split())
S = str(input())

S2 = ''

for i in range(len(S)):
    if i == K-1:
        S2 = S2 + S[K-1].replace('A', 'a').replace('B', 'b').replace('C', 'c')
    else:
        S2 = S2 + S[i]

print(S2)

Submission status: Accepted

Solution code:
n,k=map(int,input().split())
l=[i for i in str(input())]

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

print(''.join(l))

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:

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

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# coding: utf-8
# Your code here!

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

# print(N)
# print(K)
# print(S)

# print(S[K - 1])

word = ''

# print(len(S))

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

# print(S)
print(word)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

print(y)

Submission status: Accepted

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

Submission status: Accepted

Solution code:

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

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

Submission status: Accepted

Solution code:

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

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

Submission status: Accepted

Solution code:
#coding : utf-8　

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)

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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


if __name__ == "__main__":
    main()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

s = list(str)

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

result = ''.join(s)

print( result )

Submission status: Accepted

Solution code:

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

print("".join(s))

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
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:])

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
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()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
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:])

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:

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

Submission status: Accepted

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

#print(s)
#print(s[0])
#print(s[2])
for i in range(k-1):
  a=a+s[i]
#print(a)
a=a+s[k-1].lower()
#print(a)
for i in range(n-k):
  a=a+s[i+k]
print(a)

Submission status: Accepted

Solution code:
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:])

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

S = input()

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
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")

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
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:])

Submission status: Accepted

Solution code:
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:])

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

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

print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

s = input()

arr = list(s)

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

print("".join(arr))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
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="")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
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()

Submission status: Accepted

Solution code:
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("")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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