import java.util.Scanner;

public class Main {
	public static void main(String[] args){
		Scanner stdIn = new Scanner(System.in);
		int K = stdIn.nextInt();
		String S = stdIn.next();
		if(S.length() > K){
			System.out.println(S.substring(0, K) + "...");
		}
		else{
			System.out.println(S);
		}
		stdIn.close();
	}
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args){
		Scanner stdIn = new Scanner(System.in);
		int K = stdIn.nextInt();
		String S = stdIn.next();
		if(S.length() > K){
			System.out.println(S.substring(0, K) + "...");
		}
		else{
			System.out.println(S);
		}
		stdIn.close();
	}
} Main public static void main(String[] args){
		Scanner stdIn = new Scanner(System.in);
		int K = stdIn.nextInt();
		String S = stdIn.next();
		if(S.length() > K){
			System.out.println(S.substring(0, K) + "...");
		}
		else{
			System.out.println(S);
		}
		stdIn.close();
	} main {
		Scanner stdIn = new Scanner(System.in);
		int K = stdIn.nextInt();
		String S = stdIn.next();
		if(S.length() > K){
			System.out.println(S.substring(0, K) + "...");
		}
		else{
			System.out.println(S);
		}
		stdIn.close();
	} Scanner stdIn = new Scanner(System.in); stdIn new Scanner(System.in) int K = stdIn.nextInt(); K stdIn.nextInt() stdIn.nextInt stdIn String S = stdIn.next(); S stdIn.next() stdIn.next stdIn if(S.length() > K){
			System.out.println(S.substring(0, K) + "...");
		}
		else{
			System.out.println(S);
		} S.length() > K S.length() S.length S K {
			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 "..." {
			System.out.println(S);
		} System.out.println(S) System.out.println System.out System System.out S stdIn.close() stdIn.close stdIn String[] args args public class Main {
	public static void main(String[] args){
		Scanner stdIn = new Scanner(System.in);
		int K = stdIn.nextInt();
		String S = stdIn.next();
		if(S.length() > K){
			System.out.println(S.substring(0, K) + "...");
		}
		else{
			System.out.println(S);
		}
		stdIn.close();
	}
} public class Main {
	public static void main(String[] args){
		Scanner stdIn = new Scanner(System.in);
		int K = stdIn.nextInt();
		String S = stdIn.next();
		if(S.length() > K){
			System.out.println(S.substring(0, K) + "...");
		}
		else{
			System.out.println(S);
		}
		stdIn.close();
	}
} Main
import java.util.Scanner;

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