import java.util.Scanner;

public class Main {
    public static void main(String args[]) {
        Scanner scan = new Scanner(System.in);
        int charLimit;
        String str, tmp;

        charLimit = scan.nextInt();
        tmp = scan.nextLine();
        str = scan.nextLine();

        if(str.length() <= charLimit) {
            System.out.println(str);
        } else {
            System.out.println(str.substring(0, charLimit) + "...");
        }

        scan.close();
        return;
    }
} import java.util.Scanner; Scanner java.util public class Main {
    public static void main(String args[]) {
        Scanner scan = new Scanner(System.in);
        int charLimit;
        String str, tmp;

        charLimit = scan.nextInt();
        tmp = scan.nextLine();
        str = scan.nextLine();

        if(str.length() <= charLimit) {
            System.out.println(str);
        } else {
            System.out.println(str.substring(0, charLimit) + "...");
        }

        scan.close();
        return;
    }
} Main public static void main(String args[]) {
        Scanner scan = new Scanner(System.in);
        int charLimit;
        String str, tmp;

        charLimit = scan.nextInt();
        tmp = scan.nextLine();
        str = scan.nextLine();

        if(str.length() <= charLimit) {
            System.out.println(str);
        } else {
            System.out.println(str.substring(0, charLimit) + "...");
        }

        scan.close();
        return;
    } main {
        Scanner scan = new Scanner(System.in);
        int charLimit;
        String str, tmp;

        charLimit = scan.nextInt();
        tmp = scan.nextLine();
        str = scan.nextLine();

        if(str.length() <= charLimit) {
            System.out.println(str);
        } else {
            System.out.println(str.substring(0, charLimit) + "...");
        }

        scan.close();
        return;
    } Scanner scan = new Scanner(System.in); scan new Scanner(System.in) int charLimit; charLimit String str str tmp; tmp charLimit = scan.nextInt() charLimit scan.nextInt() scan.nextInt scan tmp = scan.nextLine() tmp scan.nextLine() scan.nextLine scan str = scan.nextLine() str scan.nextLine() scan.nextLine scan if(str.length() <= charLimit) {
            System.out.println(str);
        } else {
            System.out.println(str.substring(0, charLimit) + "...");
        } str.length() <= charLimit str.length() str.length str charLimit {
            System.out.println(str);
        } System.out.println(str) System.out.println System.out System System.out str {
            System.out.println(str.substring(0, charLimit) + "...");
        } System.out.println(str.substring(0, charLimit) + "...") System.out.println System.out System System.out str.substring(0, charLimit) + "..." str.substring(0, charLimit) str.substring str 0 charLimit "..." scan.close() scan.close scan return; String args[] args public class Main {
    public static void main(String args[]) {
        Scanner scan = new Scanner(System.in);
        int charLimit;
        String str, tmp;

        charLimit = scan.nextInt();
        tmp = scan.nextLine();
        str = scan.nextLine();

        if(str.length() <= charLimit) {
            System.out.println(str);
        } else {
            System.out.println(str.substring(0, charLimit) + "...");
        }

        scan.close();
        return;
    }
} public class Main {
    public static void main(String args[]) {
        Scanner scan = new Scanner(System.in);
        int charLimit;
        String str, tmp;

        charLimit = scan.nextInt();
        tmp = scan.nextLine();
        str = scan.nextLine();

        if(str.length() <= charLimit) {
            System.out.println(str);
        } else {
            System.out.println(str.substring(0, charLimit) + "...");
        }

        scan.close();
        return;
    }
} Main
import java.util.Scanner;

public class Main {
    public static void main(String args[]) {
        Scanner scan = new Scanner(System.in);
        int charLimit;
        String str, tmp;

        charLimit = scan.nextInt();
        tmp = scan.nextLine();
        str = scan.nextLine();

        if(str.length() <= charLimit) {
            System.out.println(str);
        } else {
            System.out.println(str.substring(0, charLimit) + "...");
        }

        scan.close();
        return;
    }
}