import java.io.*;
import java.util.*;

public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputstream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputstream);
        AtcoderB solution = new AtcoderB();
        solution.solve(1, in, out);
        out.flush();
        out.close();
    }

    static class AtcoderB {
        public void solve(int testNumber, Scanner sc, PrintWriter out) {
            int k = sc.nextInt();
            String s = sc.next();
            if (s.length() <= k)
                out.println(s);
            else
                out.print(s.substring(0, k) + "...");
        }
    }
    static class Scanner {
        StringTokenizer st;
        BufferedReader br;

        public Scanner(InputStream s) {
            br = new BufferedReader(new InputStreamReader(s));
        }

        public Scanner(FileReader f) {
            br = new BufferedReader(f);
        }

        public String next() {
            while (st == null || !st.hasMoreTokens())
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                }
            return st.nextToken();
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }
    }
} import java.io.*; io.* java import java.util.*; util.* java public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputstream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputstream);
        AtcoderB solution = new AtcoderB();
        solution.solve(1, in, out);
        out.flush();
        out.close();
    }

    static class AtcoderB {
        public void solve(int testNumber, Scanner sc, PrintWriter out) {
            int k = sc.nextInt();
            String s = sc.next();
            if (s.length() <= k)
                out.println(s);
            else
                out.print(s.substring(0, k) + "...");
        }
    }
    static class Scanner {
        StringTokenizer st;
        BufferedReader br;

        public Scanner(InputStream s) {
            br = new BufferedReader(new InputStreamReader(s));
        }

        public Scanner(FileReader f) {
            br = new BufferedReader(f);
        }

        public String next() {
            while (st == null || !st.hasMoreTokens())
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                }
            return st.nextToken();
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }
    }
} Main public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputstream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputstream);
        AtcoderB solution = new AtcoderB();
        solution.solve(1, in, out);
        out.flush();
        out.close();
    } main {
        InputStream inputStream = System.in;
        OutputStream outputstream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputstream);
        AtcoderB solution = new AtcoderB();
        solution.solve(1, in, out);
        out.flush();
        out.close();
    } InputStream inputStream = System.in; inputStream System.in System System.in OutputStream outputstream = System.out; outputstream System.out System System.out Scanner in = new Scanner(inputStream); in new Scanner(inputStream) PrintWriter out = new PrintWriter(outputstream); out new PrintWriter(outputstream) AtcoderB solution = new AtcoderB(); solution new AtcoderB() solution.solve(1, in, out) solution.solve solution 1 in out out.flush() out.flush out out.close() out.close out String[] args args static class AtcoderB {
        public void solve(int testNumber, Scanner sc, PrintWriter out) {
            int k = sc.nextInt();
            String s = sc.next();
            if (s.length() <= k)
                out.println(s);
            else
                out.print(s.substring(0, k) + "...");
        }
    } AtcoderB public void solve(int testNumber, Scanner sc, PrintWriter out) {
            int k = sc.nextInt();
            String s = sc.next();
            if (s.length() <= k)
                out.println(s);
            else
                out.print(s.substring(0, k) + "...");
        } solve {
            int k = sc.nextInt();
            String s = sc.next();
            if (s.length() <= k)
                out.println(s);
            else
                out.print(s.substring(0, k) + "...");
        } int k = sc.nextInt(); k sc.nextInt() sc.nextInt sc String s = sc.next(); s sc.next() sc.next sc if (s.length() <= k)
                out.println(s);
            else
                out.print(s.substring(0, k) + "..."); s.length() <= k s.length() s.length s k out.println(s) out.println out s out.print(s.substring(0, k) + "...") out.print out s.substring(0, k) + "..." s.substring(0, k) s.substring s 0 k "..." int testNumber testNumber Scanner sc sc PrintWriter out out static class Scanner {
        StringTokenizer st;
        BufferedReader br;

        public Scanner(InputStream s) {
            br = new BufferedReader(new InputStreamReader(s));
        }

        public Scanner(FileReader f) {
            br = new BufferedReader(f);
        }

        public String next() {
            while (st == null || !st.hasMoreTokens())
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                }
            return st.nextToken();
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }
    } Scanner StringTokenizer st; st BufferedReader br; br public Scanner(InputStream s) {
            br = new BufferedReader(new InputStreamReader(s));
        } Scanner {
            br = new BufferedReader(new InputStreamReader(s));
        } br = new BufferedReader(new InputStreamReader(s)) br new BufferedReader(new InputStreamReader(s)) InputStream s s public Scanner(FileReader f) {
            br = new BufferedReader(f);
        } Scanner {
            br = new BufferedReader(f);
        } br = new BufferedReader(f) br new BufferedReader(f) FileReader f f public String next() {
            while (st == null || !st.hasMoreTokens())
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                }
            return st.nextToken();
        } next {
            while (st == null || !st.hasMoreTokens())
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                }
            return st.nextToken();
        } while (st == null || !st.hasMoreTokens())
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                } st == null || !st.hasMoreTokens() st == null st null !st.hasMoreTokens() st.hasMoreTokens() st.hasMoreTokens st try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                } catch (Exception e) {
                } Exception e {
                } {
                    st = new StringTokenizer(br.readLine());
                } st = new StringTokenizer(br.readLine()) st new StringTokenizer(br.readLine()) return st.nextToken(); st.nextToken() st.nextToken st public int nextInt() {
            return Integer.parseInt(next());
        } nextInt {
            return Integer.parseInt(next());
        } return Integer.parseInt(next()); Integer.parseInt(next()) Integer.parseInt Integer next() next public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputstream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputstream);
        AtcoderB solution = new AtcoderB();
        solution.solve(1, in, out);
        out.flush();
        out.close();
    }

    static class AtcoderB {
        public void solve(int testNumber, Scanner sc, PrintWriter out) {
            int k = sc.nextInt();
            String s = sc.next();
            if (s.length() <= k)
                out.println(s);
            else
                out.print(s.substring(0, k) + "...");
        }
    }
    static class Scanner {
        StringTokenizer st;
        BufferedReader br;

        public Scanner(InputStream s) {
            br = new BufferedReader(new InputStreamReader(s));
        }

        public Scanner(FileReader f) {
            br = new BufferedReader(f);
        }

        public String next() {
            while (st == null || !st.hasMoreTokens())
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                }
            return st.nextToken();
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }
    }
} public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputstream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputstream);
        AtcoderB solution = new AtcoderB();
        solution.solve(1, in, out);
        out.flush();
        out.close();
    }

    static class AtcoderB {
        public void solve(int testNumber, Scanner sc, PrintWriter out) {
            int k = sc.nextInt();
            String s = sc.next();
            if (s.length() <= k)
                out.println(s);
            else
                out.print(s.substring(0, k) + "...");
        }
    }
    static class Scanner {
        StringTokenizer st;
        BufferedReader br;

        public Scanner(InputStream s) {
            br = new BufferedReader(new InputStreamReader(s));
        }

        public Scanner(FileReader f) {
            br = new BufferedReader(f);
        }

        public String next() {
            while (st == null || !st.hasMoreTokens())
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                }
            return st.nextToken();
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }
    }
} Main
import java.io.*;
import java.util.*;

public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputstream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputstream);
        AtcoderB solution = new AtcoderB();
        solution.solve(1, in, out);
        out.flush();
        out.close();
    }

    static class AtcoderB {
        public void solve(int testNumber, Scanner sc, PrintWriter out) {
            int k = sc.nextInt();
            String s = sc.next();
            if (s.length() <= k)
                out.println(s);
            else
                out.print(s.substring(0, k) + "...");
        }
    }
    static class Scanner {
        StringTokenizer st;
        BufferedReader br;

        public Scanner(InputStream s) {
            br = new BufferedReader(new InputStreamReader(s));
        }

        public Scanner(FileReader f) {
            br = new BufferedReader(f);
        }

        public String next() {
            while (st == null || !st.hasMoreTokens())
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                }
            return st.nextToken();
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }
    }
}
