import java.util.Scanner;
 
public class Main {
    public static void main(String[] args){
        Scanner in = new Scanner(System.in);
      String k = in.nextLine();  
      String S = in.nextLine();
      int K = Integer.parseInt(k);
     
      if (S.length()<=K){
          System.out.println(S);
         }
         else {
           System.out.println(S.substring(0,K)+ "...");
                }
        }
    } import java.util.Scanner; Scanner java.util public class Main {
    public static void main(String[] args){
        Scanner in = new Scanner(System.in);
      String k = in.nextLine();  
      String S = in.nextLine();
      int K = Integer.parseInt(k);
     
      if (S.length()<=K){
          System.out.println(S);
         }
         else {
           System.out.println(S.substring(0,K)+ "...");
                }
        }
    } Main public static void main(String[] args){
        Scanner in = new Scanner(System.in);
      String k = in.nextLine();  
      String S = in.nextLine();
      int K = Integer.parseInt(k);
     
      if (S.length()<=K){
          System.out.println(S);
         }
         else {
           System.out.println(S.substring(0,K)+ "...");
                }
        } main {
        Scanner in = new Scanner(System.in);
      String k = in.nextLine();  
      String S = in.nextLine();
      int K = Integer.parseInt(k);
     
      if (S.length()<=K){
          System.out.println(S);
         }
         else {
           System.out.println(S.substring(0,K)+ "...");
                }
        } Scanner in = new Scanner(System.in); in new Scanner(System.in) String k = in.nextLine(); k in.nextLine() in.nextLine in String S = in.nextLine(); S in.nextLine() in.nextLine in int K = Integer.parseInt(k); K Integer.parseInt(k) Integer.parseInt Integer k if (S.length()<=K){
          System.out.println(S);
         }
         else {
           System.out.println(S.substring(0,K)+ "...");
                } S.length()<=K S.length() S.length S K {
          System.out.println(S);
         } System.out.println(S) System.out.println System.out System System.out S {
           System.out.println(S.substring(0,K)+ "...");
                } System.out.println(S.substring(0,K)+ "...") System.out.println System.out System System.out S.substring(0,K)+ "..." S.substring(0,K) S.substring S 0 K "..." String[] args args public class Main {
    public static void main(String[] args){
        Scanner in = new Scanner(System.in);
      String k = in.nextLine();  
      String S = in.nextLine();
      int K = Integer.parseInt(k);
     
      if (S.length()<=K){
          System.out.println(S);
         }
         else {
           System.out.println(S.substring(0,K)+ "...");
                }
        }
    } public class Main {
    public static void main(String[] args){
        Scanner in = new Scanner(System.in);
      String k = in.nextLine();  
      String S = in.nextLine();
      int K = Integer.parseInt(k);
     
      if (S.length()<=K){
          System.out.println(S);
         }
         else {
           System.out.println(S.substring(0,K)+ "...");
                }
        }
    } Main
import java.util.Scanner;
 
public class Main {
    public static void main(String[] args){
        Scanner in = new Scanner(System.in);
      String k = in.nextLine();  
      String S = in.nextLine();
      int K = Integer.parseInt(k);
     
      if (S.length()<=K){
          System.out.println(S);
         }
         else {
           System.out.println(S.substring(0,K)+ "...");
                }
        }
    }
