#include <bits/stdc++.h>
int main() {
  int K;
  while (scanf("%d", &K) == 0)
    ;
  char S[101];
  while (scanf("%s", S) == 0)
    ;
  int l = strlen(S);
  char a[] = "...";
  char T[101];
  int i;
  for (i = 0; i < K; i++) {
    T[i] = S[i];
  }
  if (l <= K) {
    printf("%s\n", S);
  } else if (l > K) {
    printf("%s%s\n", T, a);
  }
  return 0;
}
