import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Main {
    public static void main(String args[]) throws IOException {

	BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
	int K = Integer.parseInt(br.readLine());
	String S = br.readLine();

	if (S.length() <= K) {
	    System.out.println(S);
	} else {
	    System.out.println(S.substring(0, K) + "...");
	}
    }
} import java.io.BufferedReader; BufferedReader java.io import java.io.IOException; IOException java.io import java.io.InputStreamReader; InputStreamReader java.io public class Main {
    public static void main(String args[]) throws IOException {

	BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
	int K = Integer.parseInt(br.readLine());
	String S = br.readLine();

	if (S.length() <= K) {
	    System.out.println(S);
	} else {
	    System.out.println(S.substring(0, K) + "...");
	}
    }
} Main public static void main(String args[]) throws IOException {

	BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
	int K = Integer.parseInt(br.readLine());
	String S = br.readLine();

	if (S.length() <= K) {
	    System.out.println(S);
	} else {
	    System.out.println(S.substring(0, K) + "...");
	}
    } main {

	BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
	int K = Integer.parseInt(br.readLine());
	String S = br.readLine();

	if (S.length() <= K) {
	    System.out.println(S);
	} else {
	    System.out.println(S.substring(0, K) + "...");
	}
    } BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) int K = Integer.parseInt(br.readLine()); K Integer.parseInt(br.readLine()) Integer.parseInt Integer br.readLine() br.readLine br String S = br.readLine(); S br.readLine() br.readLine br if (S.length() <= K) {
	    System.out.println(S);
	} else {
	    System.out.println(S.substring(0, K) + "...");
	} 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 {
	    System.out.println(S.substring(0, K) + "...");
	} System.out.println(S.substring(0, K) + "...") System.out.println System.out System System.out S.substring(0, K) + "..." S.substring(0, K) S.substring S 0 K "..." String args[] args public class Main {
    public static void main(String args[]) throws IOException {

	BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
	int K = Integer.parseInt(br.readLine());
	String S = br.readLine();

	if (S.length() <= K) {
	    System.out.println(S);
	} else {
	    System.out.println(S.substring(0, K) + "...");
	}
    }
} public class Main {
    public static void main(String args[]) throws IOException {

	BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
	int K = Integer.parseInt(br.readLine());
	String S = br.readLine();

	if (S.length() <= K) {
	    System.out.println(S);
	} else {
	    System.out.println(S.substring(0, K) + "...");
	}
    }
} Main
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Main {
    public static void main(String args[]) throws IOException {

	BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
	int K = Integer.parseInt(br.readLine());
	String S = br.readLine();

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