import java.util.Scanner;

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

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