import java.util.*;
import java.math.*;
 
public class Main { //クラス名はMain
    public static void main(String[] args) {
      //整数の入力
      Scanner sc = new Scanner(System.in);
      Integer K = Integer.parseInt(sc.next());
      String S = sc.next();

      String answer = K >= S.length() ? S : S.substring(0,K) + "...";

      System.out.println(answer);
    }
} import java.util.*; util.* java import java.math.*; math.* java public class Main { //クラス名はMain
    public static void main(String[] args) {
      //整数の入力
      Scanner sc = new Scanner(System.in);
      Integer K = Integer.parseInt(sc.next());
      String S = sc.next();

      String answer = K >= S.length() ? S : S.substring(0,K) + "...";

      System.out.println(answer);
    }
} Main public static void main(String[] args) {
      //整数の入力
      Scanner sc = new Scanner(System.in);
      Integer K = Integer.parseInt(sc.next());
      String S = sc.next();

      String answer = K >= S.length() ? S : S.substring(0,K) + "...";

      System.out.println(answer);
    } main {
      //整数の入力
      Scanner sc = new Scanner(System.in);
      Integer K = Integer.parseInt(sc.next());
      String S = sc.next();

      String answer = K >= S.length() ? S : S.substring(0,K) + "...";

      System.out.println(answer);
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) Integer K = Integer.parseInt(sc.next()); K Integer.parseInt(sc.next()) Integer.parseInt Integer sc.next() sc.next sc String S = sc.next(); S sc.next() sc.next sc String answer = K >= S.length() ? S : S.substring(0,K) + "..."; answer K >= S.length() ? S : S.substring(0,K) + "..." K >= S.length() K S.length() S.length S S S.substring(0,K) + "..." S.substring(0,K) S.substring S 0 K "..." System.out.println(answer) System.out.println System.out System System.out answer String[] args args public class Main { //クラス名はMain
    public static void main(String[] args) {
      //整数の入力
      Scanner sc = new Scanner(System.in);
      Integer K = Integer.parseInt(sc.next());
      String S = sc.next();

      String answer = K >= S.length() ? S : S.substring(0,K) + "...";

      System.out.println(answer);
    }
} public class Main { //クラス名はMain
    public static void main(String[] args) {
      //整数の入力
      Scanner sc = new Scanner(System.in);
      Integer K = Integer.parseInt(sc.next());
      String S = sc.next();

      String answer = K >= S.length() ? S : S.substring(0,K) + "...";

      System.out.println(answer);
    }
} Main
import java.util.*;
import java.math.*;
 
public class Main { //クラス名はMain
    public static void main(String[] args) {
      //整数の入力
      Scanner sc = new Scanner(System.in);
      Integer K = Integer.parseInt(sc.next());
      String S = sc.next();

      String answer = K >= S.length() ? S : S.substring(0,K) + "...";

      System.out.println(answer);
    }
}
