import java.util.Scanner;

public class Main {

    public static void main(String args[]){
        Scanner scanner = new Scanner(System.in);
        int n = Integer.parseInt(scanner.nextLine());
        String S = scanner.nextLine();

        if(n >= S.length()){
            System.out.println(S);
        } else {
            System.out.println(S.substring(0, n)+"...");
        }

        scanner.close();
    }

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

    public static void main(String args[]){
        Scanner scanner = new Scanner(System.in);
        int n = Integer.parseInt(scanner.nextLine());
        String S = scanner.nextLine();

        if(n >= S.length()){
            System.out.println(S);
        } else {
            System.out.println(S.substring(0, n)+"...");
        }

        scanner.close();
    }

} Main public static void main(String args[]){
        Scanner scanner = new Scanner(System.in);
        int n = Integer.parseInt(scanner.nextLine());
        String S = scanner.nextLine();

        if(n >= S.length()){
            System.out.println(S);
        } else {
            System.out.println(S.substring(0, n)+"...");
        }

        scanner.close();
    } main {
        Scanner scanner = new Scanner(System.in);
        int n = Integer.parseInt(scanner.nextLine());
        String S = scanner.nextLine();

        if(n >= S.length()){
            System.out.println(S);
        } else {
            System.out.println(S.substring(0, n)+"...");
        }

        scanner.close();
    } Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) int n = Integer.parseInt(scanner.nextLine()); n Integer.parseInt(scanner.nextLine()) Integer.parseInt Integer scanner.nextLine() scanner.nextLine scanner String S = scanner.nextLine(); S scanner.nextLine() scanner.nextLine scanner if(n >= S.length()){
            System.out.println(S);
        } else {
            System.out.println(S.substring(0, n)+"...");
        } n >= S.length() n S.length() S.length S {
            System.out.println(S);
        } System.out.println(S) System.out.println System.out System System.out S {
            System.out.println(S.substring(0, n)+"...");
        } System.out.println(S.substring(0, n)+"...") System.out.println System.out System System.out S.substring(0, n)+"..." S.substring(0, n) S.substring S 0 n "..." scanner.close() scanner.close scanner String args[] args public class Main {

    public static void main(String args[]){
        Scanner scanner = new Scanner(System.in);
        int n = Integer.parseInt(scanner.nextLine());
        String S = scanner.nextLine();

        if(n >= S.length()){
            System.out.println(S);
        } else {
            System.out.println(S.substring(0, n)+"...");
        }

        scanner.close();
    }

} public class Main {

    public static void main(String args[]){
        Scanner scanner = new Scanner(System.in);
        int n = Integer.parseInt(scanner.nextLine());
        String S = scanner.nextLine();

        if(n >= S.length()){
            System.out.println(S);
        } else {
            System.out.println(S.substring(0, n)+"...");
        }

        scanner.close();
    }

} Main
import java.util.Scanner;

public class Main {

    public static void main(String args[]){
        Scanner scanner = new Scanner(System.in);
        int n = Integer.parseInt(scanner.nextLine());
        String S = scanner.nextLine();

        if(n >= S.length()){
            System.out.println(S);
        } else {
            System.out.println(S.substring(0, n)+"...");
        }

        scanner.close();
    }

}
