function Main(input) {
    var K = parseInt(input[0], 10);
    var S = input[1];
    
    if (S.length > K) {
        console.log(`${S.substring(0, K)}...`);
    } else {
        console.log(S);
    }
}

Main(require("fs").readFileSync("/dev/stdin", "utf8").trim().split(/\n|\s/));