import java.util.*;

public class Main {

    public static void main(String args[]) {


        Scanner scan = new Scanner(System.in);

        int k = scan.nextInt();
        String s = scan.next();

        if (s.length() <= k) {
            System.out.println(s);
        } else {
            String n = s.substring(0, k).concat("...");
            System.out.println(n);
        }

    }


} import java.util.*; util.* java public class Main {

    public static void main(String args[]) {


        Scanner scan = new Scanner(System.in);

        int k = scan.nextInt();
        String s = scan.next();

        if (s.length() <= k) {
            System.out.println(s);
        } else {
            String n = s.substring(0, k).concat("...");
            System.out.println(n);
        }

    }


} Main public static void main(String args[]) {


        Scanner scan = new Scanner(System.in);

        int k = scan.nextInt();
        String s = scan.next();

        if (s.length() <= k) {
            System.out.println(s);
        } else {
            String n = s.substring(0, k).concat("...");
            System.out.println(n);
        }

    } main {


        Scanner scan = new Scanner(System.in);

        int k = scan.nextInt();
        String s = scan.next();

        if (s.length() <= k) {
            System.out.println(s);
        } else {
            String n = s.substring(0, k).concat("...");
            System.out.println(n);
        }

    } Scanner scan = new Scanner(System.in); scan new Scanner(System.in) int k = scan.nextInt(); k scan.nextInt() scan.nextInt scan String s = scan.next(); s scan.next() scan.next scan if (s.length() <= k) {
            System.out.println(s);
        } else {
            String n = s.substring(0, k).concat("...");
            System.out.println(n);
        } 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 {
            String n = s.substring(0, k).concat("...");
            System.out.println(n);
        } String n = s.substring(0, k).concat("..."); n s.substring(0, k).concat("...") s.substring(0, k).concat s.substring(0, k) s.substring s 0 k "..." System.out.println(n) System.out.println System.out System System.out n String args[] args public class Main {

    public static void main(String args[]) {


        Scanner scan = new Scanner(System.in);

        int k = scan.nextInt();
        String s = scan.next();

        if (s.length() <= k) {
            System.out.println(s);
        } else {
            String n = s.substring(0, k).concat("...");
            System.out.println(n);
        }

    }


} public class Main {

    public static void main(String args[]) {


        Scanner scan = new Scanner(System.in);

        int k = scan.nextInt();
        String s = scan.next();

        if (s.length() <= k) {
            System.out.println(s);
        } else {
            String n = s.substring(0, k).concat("...");
            System.out.println(n);
        }

    }


} Main
import java.util.*;

public class Main {

    public static void main(String args[]) {


        Scanner scan = new Scanner(System.in);

        int k = scan.nextInt();
        String s = scan.next();

        if (s.length() <= k) {
            System.out.println(s);
        } else {
            String n = s.substring(0, k).concat("...");
            System.out.println(n);
        }

    }


}