import java.util.*;
public class Main {
    public static void main(String[] args){
      Scanner scan = new Scanner(System.in);
      int n = scan.nextInt();
      int k = scan.nextInt();
      String s = scan.next();
      StringBuffer sb = new StringBuffer();
      for (int i = 0; i < s.length(); i++) {
        char temp = s.charAt(i);
        if(i==k-1) {
          temp = (char)(temp+32);
        }
        sb.append(temp);
      }
      
			System.out.println(sb.toString());
    }
} import java.util.*; util.* java public class Main {
    public static void main(String[] args){
      Scanner scan = new Scanner(System.in);
      int n = scan.nextInt();
      int k = scan.nextInt();
      String s = scan.next();
      StringBuffer sb = new StringBuffer();
      for (int i = 0; i < s.length(); i++) {
        char temp = s.charAt(i);
        if(i==k-1) {
          temp = (char)(temp+32);
        }
        sb.append(temp);
      }
      
			System.out.println(sb.toString());
    }
} Main public static void main(String[] args){
      Scanner scan = new Scanner(System.in);
      int n = scan.nextInt();
      int k = scan.nextInt();
      String s = scan.next();
      StringBuffer sb = new StringBuffer();
      for (int i = 0; i < s.length(); i++) {
        char temp = s.charAt(i);
        if(i==k-1) {
          temp = (char)(temp+32);
        }
        sb.append(temp);
      }
      
			System.out.println(sb.toString());
    } main {
      Scanner scan = new Scanner(System.in);
      int n = scan.nextInt();
      int k = scan.nextInt();
      String s = scan.next();
      StringBuffer sb = new StringBuffer();
      for (int i = 0; i < s.length(); i++) {
        char temp = s.charAt(i);
        if(i==k-1) {
          temp = (char)(temp+32);
        }
        sb.append(temp);
      }
      
			System.out.println(sb.toString());
    } Scanner scan = new Scanner(System.in); scan new Scanner(System.in) int n = scan.nextInt(); n scan.nextInt() scan.nextInt scan int k = scan.nextInt(); k scan.nextInt() scan.nextInt scan String s = scan.next(); s scan.next() scan.next scan StringBuffer sb = new StringBuffer(); sb new StringBuffer() for (int i = 0; i < s.length(); i++) {
        char temp = s.charAt(i);
        if(i==k-1) {
          temp = (char)(temp+32);
        }
        sb.append(temp);
      } int i = 0; int i = 0; i 0 i < s.length() i s.length() s.length s i++ i++ i {
        char temp = s.charAt(i);
        if(i==k-1) {
          temp = (char)(temp+32);
        }
        sb.append(temp);
      } {
        char temp = s.charAt(i);
        if(i==k-1) {
          temp = (char)(temp+32);
        }
        sb.append(temp);
      } char temp = s.charAt(i); temp s.charAt(i) s.charAt s i if(i==k-1) {
          temp = (char)(temp+32);
        } i==k-1 i k-1 k 1 {
          temp = (char)(temp+32);
        } temp = (char)(temp+32) temp (char)(temp+32) temp 32 sb.append(temp) sb.append sb temp System.out.println(sb.toString()) System.out.println System.out System System.out sb.toString() sb.toString sb String[] args args public class Main {
    public static void main(String[] args){
      Scanner scan = new Scanner(System.in);
      int n = scan.nextInt();
      int k = scan.nextInt();
      String s = scan.next();
      StringBuffer sb = new StringBuffer();
      for (int i = 0; i < s.length(); i++) {
        char temp = s.charAt(i);
        if(i==k-1) {
          temp = (char)(temp+32);
        }
        sb.append(temp);
      }
      
			System.out.println(sb.toString());
    }
} public class Main {
    public static void main(String[] args){
      Scanner scan = new Scanner(System.in);
      int n = scan.nextInt();
      int k = scan.nextInt();
      String s = scan.next();
      StringBuffer sb = new StringBuffer();
      for (int i = 0; i < s.length(); i++) {
        char temp = s.charAt(i);
        if(i==k-1) {
          temp = (char)(temp+32);
        }
        sb.append(temp);
      }
      
			System.out.println(sb.toString());
    }
} Main
import java.util.*;
public class Main {
    public static void main(String[] args){
      Scanner scan = new Scanner(System.in);
      int n = scan.nextInt();
      int k = scan.nextInt();
      String s = scan.next();
      StringBuffer sb = new StringBuffer();
      for (int i = 0; i < s.length(); i++) {
        char temp = s.charAt(i);
        if(i==k-1) {
          temp = (char)(temp+32);
        }
        sb.append(temp);
      }
      
			System.out.println(sb.toString());
    }
}
