import java.util.*;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int K = sc.nextInt();
        String S = sc.next();
        String tmp;
        if(S.length() > K) {
            tmp = S.substring(0,K);
            tmp = tmp + "...";
        } else {
            tmp = S;
        }
        System.out.println(tmp);
    }
} import java.util.*; util.* java public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int K = sc.nextInt();
        String S = sc.next();
        String tmp;
        if(S.length() > K) {
            tmp = S.substring(0,K);
            tmp = tmp + "...";
        } else {
            tmp = S;
        }
        System.out.println(tmp);
    }
} Main public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int K = sc.nextInt();
        String S = sc.next();
        String tmp;
        if(S.length() > K) {
            tmp = S.substring(0,K);
            tmp = tmp + "...";
        } else {
            tmp = S;
        }
        System.out.println(tmp);
    } main {
        Scanner sc = new Scanner(System.in);
        int K = sc.nextInt();
        String S = sc.next();
        String tmp;
        if(S.length() > K) {
            tmp = S.substring(0,K);
            tmp = tmp + "...";
        } else {
            tmp = S;
        }
        System.out.println(tmp);
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int K = sc.nextInt(); K sc.nextInt() sc.nextInt sc String S = sc.next(); S sc.next() sc.next sc String tmp; tmp if(S.length() > K) {
            tmp = S.substring(0,K);
            tmp = tmp + "...";
        } else {
            tmp = S;
        } S.length() > K S.length() S.length S K {
            tmp = S.substring(0,K);
            tmp = tmp + "...";
        } tmp = S.substring(0,K) tmp S.substring(0,K) S.substring S 0 K tmp = tmp + "..." tmp tmp + "..." tmp "..." {
            tmp = S;
        } tmp = S tmp S System.out.println(tmp) System.out.println System.out System System.out tmp String[] args args public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int K = sc.nextInt();
        String S = sc.next();
        String tmp;
        if(S.length() > K) {
            tmp = S.substring(0,K);
            tmp = tmp + "...";
        } else {
            tmp = S;
        }
        System.out.println(tmp);
    }
} public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int K = sc.nextInt();
        String S = sc.next();
        String tmp;
        if(S.length() > K) {
            tmp = S.substring(0,K);
            tmp = tmp + "...";
        } else {
            tmp = S;
        }
        System.out.println(tmp);
    }
} Main
import java.util.*;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int K = sc.nextInt();
        String S = sc.next();
        String tmp;
        if(S.length() > K) {
            tmp = S.substring(0,K);
            tmp = tmp + "...";
        } else {
            tmp = S;
        }
        System.out.println(tmp);
    }
}