function main(input){
  input = input.split('\n');
  const k = Number(input[0]);
  const s = input[1];
  
  if(s.length <= k){
    console.log(s);
  }else{
    console.log(s.slice(0, k) + '...');
  }
  
}

main(require('fs').readFileSync('/dev/stdin', 'utf8').trim());