import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner in = new Scanner(System.in);
		int k = Integer.parseInt(in.nextLine());
		String s = in.nextLine();
		if(s.length() > k) {
			String mod_s = s.substring(0,k) + "...";
			System.out.println(mod_s);
		} else {
			System.out.println(s);
		}
	}
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {
		Scanner in = new Scanner(System.in);
		int k = Integer.parseInt(in.nextLine());
		String s = in.nextLine();
		if(s.length() > k) {
			String mod_s = s.substring(0,k) + "...";
			System.out.println(mod_s);
		} else {
			System.out.println(s);
		}
	}
} Main public static void main(String[] args) {
		Scanner in = new Scanner(System.in);
		int k = Integer.parseInt(in.nextLine());
		String s = in.nextLine();
		if(s.length() > k) {
			String mod_s = s.substring(0,k) + "...";
			System.out.println(mod_s);
		} else {
			System.out.println(s);
		}
	} main {
		Scanner in = new Scanner(System.in);
		int k = Integer.parseInt(in.nextLine());
		String s = in.nextLine();
		if(s.length() > k) {
			String mod_s = s.substring(0,k) + "...";
			System.out.println(mod_s);
		} else {
			System.out.println(s);
		}
	} Scanner in = new Scanner(System.in); in new Scanner(System.in) int k = Integer.parseInt(in.nextLine()); k Integer.parseInt(in.nextLine()) Integer.parseInt Integer in.nextLine() in.nextLine in String s = in.nextLine(); s in.nextLine() in.nextLine in if(s.length() > k) {
			String mod_s = s.substring(0,k) + "...";
			System.out.println(mod_s);
		} else {
			System.out.println(s);
		} s.length() > k s.length() s.length s k {
			String mod_s = s.substring(0,k) + "...";
			System.out.println(mod_s);
		} String mod_s = s.substring(0,k) + "..."; mod_s s.substring(0,k) + "..." s.substring(0,k) s.substring s 0 k "..." System.out.println(mod_s) System.out.println System.out System System.out mod_s {
			System.out.println(s);
		} System.out.println(s) System.out.println System.out System System.out s String[] args args public class Main {
	public static void main(String[] args) {
		Scanner in = new Scanner(System.in);
		int k = Integer.parseInt(in.nextLine());
		String s = in.nextLine();
		if(s.length() > k) {
			String mod_s = s.substring(0,k) + "...";
			System.out.println(mod_s);
		} else {
			System.out.println(s);
		}
	}
} public class Main {
	public static void main(String[] args) {
		Scanner in = new Scanner(System.in);
		int k = Integer.parseInt(in.nextLine());
		String s = in.nextLine();
		if(s.length() > k) {
			String mod_s = s.substring(0,k) + "...";
			System.out.println(mod_s);
		} else {
			System.out.println(s);
		}
	}
} Main
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner in = new Scanner(System.in);
		int k = Integer.parseInt(in.nextLine());
		String s = in.nextLine();
		if(s.length() > k) {
			String mod_s = s.substring(0,k) + "...";
			System.out.println(mod_s);
		} else {
			System.out.println(s);
		}
	}
}