import java.util.*;
    public class Main{ 
    public static void main(String arg[]){
		Scanner sc=new Scanner(System.in);
		int a=sc.nextInt();
		int b=sc.nextInt();
		String s=sc.next();
		char ch[]=s.toCharArray();
		ch[b-1]=Character.toLowerCase(ch[b-1]);
		String s1=new String(ch);
		System.out.println(s1);
	}
} import java.util.*; util.* java public class Main{ 
    public static void main(String arg[]){
		Scanner sc=new Scanner(System.in);
		int a=sc.nextInt();
		int b=sc.nextInt();
		String s=sc.next();
		char ch[]=s.toCharArray();
		ch[b-1]=Character.toLowerCase(ch[b-1]);
		String s1=new String(ch);
		System.out.println(s1);
	}
} Main public static void main(String arg[]){
		Scanner sc=new Scanner(System.in);
		int a=sc.nextInt();
		int b=sc.nextInt();
		String s=sc.next();
		char ch[]=s.toCharArray();
		ch[b-1]=Character.toLowerCase(ch[b-1]);
		String s1=new String(ch);
		System.out.println(s1);
	} main {
		Scanner sc=new Scanner(System.in);
		int a=sc.nextInt();
		int b=sc.nextInt();
		String s=sc.next();
		char ch[]=s.toCharArray();
		ch[b-1]=Character.toLowerCase(ch[b-1]);
		String s1=new String(ch);
		System.out.println(s1);
	} Scanner sc=new Scanner(System.in); sc new Scanner(System.in) int a=sc.nextInt(); a sc.nextInt() sc.nextInt sc int b=sc.nextInt(); b sc.nextInt() sc.nextInt sc String s=sc.next(); s sc.next() sc.next sc char ch[]=s.toCharArray(); ch s.toCharArray() s.toCharArray s ch[b-1]=Character.toLowerCase(ch[b-1]) ch[b-1] ch b-1 b 1 Character.toLowerCase(ch[b-1]) Character.toLowerCase Character ch[b-1] ch b-1 b 1 String s1=new String(ch); s1 new String(ch) System.out.println(s1) System.out.println System.out System System.out s1 String arg[] arg public class Main{ 
    public static void main(String arg[]){
		Scanner sc=new Scanner(System.in);
		int a=sc.nextInt();
		int b=sc.nextInt();
		String s=sc.next();
		char ch[]=s.toCharArray();
		ch[b-1]=Character.toLowerCase(ch[b-1]);
		String s1=new String(ch);
		System.out.println(s1);
	}
} public class Main{ 
    public static void main(String arg[]){
		Scanner sc=new Scanner(System.in);
		int a=sc.nextInt();
		int b=sc.nextInt();
		String s=sc.next();
		char ch[]=s.toCharArray();
		ch[b-1]=Character.toLowerCase(ch[b-1]);
		String s1=new String(ch);
		System.out.println(s1);
	}
} Main
import java.util.*;
    public class Main{ 
    public static void main(String arg[]){
		Scanner sc=new Scanner(System.in);
		int a=sc.nextInt();
		int b=sc.nextInt();
		String s=sc.next();
		char ch[]=s.toCharArray();
		ch[b-1]=Character.toLowerCase(ch[b-1]);
		String s1=new String(ch);
		System.out.println(s1);
	}
}