Problem:
 Score: 200 points    Problem Statement  We have a string S consisting of lowercase English letters.  If the length of S is at most K , print S without change.  If the length of S exceeds K , extract the first K characters in S , append ... to the end of them, and print the result.      Constraints   K is an integer between 1 and 100 (inclusive).  S is a string consisting of lowercase English letters.  The length of S is between 1 and 100 (inclusive).         Input  Input is given from Standard Input in the following format:  K  S       Output  Print a string as stated in Problem Statement.        Sample Input 1 7
nikoandsolstice      Sample Output 1 nikoand...  nikoandsolstice has a length of 15 , which exceeds K=7 .  We should extract the first 7 characters in this string, append ... to the end of them, and print the result nikoand... .       Sample Input 2 40
ferelibenterhominesidquodvoluntcredunt      Sample Output 2 ferelibenterhominesidquodvoluntcredunt  The famous quote from Gaius Julius Caesar.

Solution (Python):
nagasa = int(input())
retsu = input()
kazu = len(retsu)
if (nagasa >= kazu):
  print(retsu)
else:
  print(retsu[0:nagasa] + '...')

Solution (Python):
k = int(input())
s = input()

if len(s) <= k:
    print(s)
else:
    print(s[:k] + "...")

Solution (Python):
import numpy as np
import math
k = int(input())
s = input()
if len(s) > k:
    print(s[:k]+'...')
else:
    print(s)

Solution (Python):
K = int(input())
S = str(input())
if len(S) <= K:
    print(S[:K])
elif len(S) > K:
    print(S[:K] + ("." * 3))

Solution (Python):
k = int(input())
s = input()
if len(s)<=k:
    print(s)
else:
    print(s[:k]+"...")

Solution (Python):
K=int(input())
S=input()

if len(S)<=K:
    print(S)
else:
    print(S[0:K]+"...")

Solution (Python):
import sys
readline = sys.stdin.buffer.readline
def even(n): return 1 if n%2==0 else 0

n = int(readline())
s = readline().rstrip().decode('utf-8')

if len(s) <= n:
    print(s)
else:
    print(s[:n]+"...")

Solution (Python):
K = int(input())
S = list(input())
length = len(S)

if length <= K:
    print(("".join(S)))
else:
    result = S[:K]
    print(("".join(result))+"...")

Solution (Python):
k = int(input())
s = input()

if len(s) > k:
    print(s[:k] + '...')
else:
    print(s)

Solution (Python):
K = int(input())
S = input()

if len(S) > K :
    print(S[:K] + "...")

else:
    print(S)

Solution (Python):



k = int(input())
s = str(input())

if len(s) > k:
  print(s[:k] + "...")
else:
  print(s)

Solution (Python):
k = int(input())
s = input()
s = s.lower()
ls = []
if len(s) <= k:
    print(s)
else:
    result = s[:k]+"..."
    print(result)

Solution (Python):
K = int(input())
S = input()

if len(S) <= K:
    print(S)
else:
    print(S[:K] + '...')

Solution (Python):
K = int(input())
S = input()

if len(S)<=K:
  print(S)
elif len(S) > K:
  print(S[0:K], end="...")

Solution (Python):
K=int(input())
S=input()
SS=list(S)
S1=len(S)
Ans=""
if S1 <= K:
    print(S)
else:
    for k in range(K):
        Ans=Ans+SS[k]
    
    print(Ans+"...")

Solution (Python):
k = input()
s = str(input())

if len(s)>int(k):
  print(s[0:int(k)]+"...")
else:
  print(s)

Solution (Python):

K = int(input())

S = input()

if len(S)<=K:
    print(S)
else:
    print(S[:K]+'...')

Solution (Python):
import sys


input = sys.stdin.readline


def main():
    if K >= len(S)-1:
        print(S)
    else:
        print(S[:K]+"...")


if __name__ == "__main__":
    K = int(input())
    S = input()
    main()

Solution (Python):
K = int(input())
S = input()
S = S[::-1]

if len(S) <= K:
    print(S[::-1])
else:
    S = S.replace(S[:len(S) - K], '...', 1)
    print(S[::-1])

Solution (Python):
K = int(input())
S = input()
 
if len(S)<=K:
  print(S)
else:
  print(S[0:K]+'...')

Solution (Python):
k=int(input())
s=input()
if int(len(s)) <= k:
    print(str(s))
else:
    print(((str(s))[0:k])+"...")

Solution (Python):
k=int(input())
s=input()
if len(s)>k:
    print(s[:k]+"...")
else:
    print(s)

Solution (Python):
k = int(input())
s = input()
if(len(s) <= k):
  print(s)
else:
  print(s[0:k] + '...')

Solution (Python):
k = int(input())
s = input()
if len(s) <= k:
	print(s)
else:
	print(s[:k] + '...')

Solution (Python):
K = int(input())
S = input()

if len(S) >  K:
    a = S[0:K] + '...'
    print(a)
else:
    print(S[0:K])

Solution (Python):
k = int(input())
s = input()

if len(s) > k:
    print(s[:k] + "...")
else:
    print(s)

Solution (Python):


k = int(input())
s = input()
l = len(s)

if l <= k:
    print(s)
else:
    print(s[:k] + '...')

Solution (Python):
kInt = int(input())
sStr = str(input())
sLen = len(sStr)

if (sLen <= kInt):
    print(sStr)
else:
    print(sStr[:kInt] + '...')

Solution (Python):
k = int(input())
s = input()

if len(s) <= k:
    print(s)
else:
    print(s[0:k] + '...')

Solution (Python):
K=int(input())
S=input()

len_s=len(S)


if len_s <= K :
    print(S)
else:
    S_cut=S[0:K]+"..."
    print(S_cut)

Solution (Python):
k = int(input())
s = input()

if len(s) <= k:
    print(s)
else:
    print(s[:k] + '...')

Solution (Python):
import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline

k = int(input())
s = input()

t = ""
a = len(s)


if k >= a:
    print(s)
else:
    print(s[:k] + "...")

Solution (Python):
K = int(input())
S = input()

if len(S) <= K:
    print(S)
else:
    print(S[0:K] + "...")

Solution (Python):
K = int(input())
S = str(input())
if len(S) <= K:
  print(S)
else :
  print(S[0:K]+"...")

Solution (Python):
K = int(input())
S = str(input())


if len(S) <= K :
    print(S)
else :
    a = S[:K] + '...'
    print(a)

Solution (Python):
K = int(input())
S = input()

if len(S) <= K:
    print(S)
else:
    s = [S[:K]]
    
    print(s[0]+'...')

Solution (Python):
K = int(input())
S = input()

if len(S) <= K:
  print(S)
else:
  print(S[0:K] + '...')

Solution (Python):
K = int(input())
S = input()
if len(S) <= K:
    print(S)
else:
    print(S[:K] + '...')

Solution (Python):
K = int(input())
S = str(input())
l = len(S)
ST = str()
if K >= l:
  for i in range(l):
    ST += str(S[i])
  print(ST)
else:
  for i in range(K):
    ST += str(S[i])
  print(ST +'...')

Solution (Python):
k = int(input())
s = input()
if k >= len(s):
  print(s)
else:
  print(s[:k]+'...')

Solution (Python):
K = int(input())
S = input()

if len(S) <= K:
  print(S)
elif len(S) > K:
  print(S[0:K] + "...")

Solution (Python):
k =int(input())
s =input()

lens = len(s)

if lens <= k:
    print(s)
else:
    for i in range(k):
        print(s[i],end='')
    print('...')

Solution (Python):
K=int(input())
S=list(input())

if len(S)<=K:
    print("".join(S))
else:
    print("".join(S[:K])+"...")

Solution (Python):
def main():
    K = int(input())
    S = input()

    if len(S) <= K :
        print(S)
    else :
        print(S[:K] + '...')

if __name__ == "__main__":
    main()

Solution (Python):
k=int(input())
s=str(input())
l=len(s)

if l<=k:
    print(s)
else:
    
    print(s[0:k] + "...")

Solution (Python):
K = int(input())
S = input()
if int(len(S)) <= K:
    print(S)
else:
    print(S[0:K]+'...')

Solution (Python):
K=int(input())
S=str(input())
if len(S) <= K:
    print(S)
elif len(S) > K:
    print(S[0:int(K)]+"...")

Solution (Python):
K = int(input())
S = input()

if len(S) <= K:
  print(S)
else:
  n = 0
  while n < K:
    print(S[n],end='')
    n += 1
  print('...')

Solution (Python):
import sys
import math
def solution():
    k=int(input())
    s=input()
    if(len(s)<=k):
        print(s)
    else:
        print(s[:k]+"...")

if __name__ == "__main__":
    solution()

Solution (Python):
K = int(input())
S = str(input())
l = len(S)
if (l<=K):
  print(S)  
else:
  print(S[0:K]+'...')

Solution (Python):

k = int(input())
s = input()

if len(s) > k:
    print(s[:k] + "...")
else:
    print(s)

Solution (Python):
k=int(input())
s=str(input())

if len(s)<=k:
    print(s)
elif len(s)>k:
    print(s[0:k]+'...')

Solution (Python):
k = int(input())
s = input()
if len(s) <= k:
    print(s)
else:
    print(s[:k] + '...')

Solution (Python):
k=int(input())
s=list(input())
if len(s)<=k:
  print("".join(s))
else:
  print("".join(s[:k])+"...")

Solution (Python):
K = int(input())
S = input()


if len(S) <= K:
    print(S)
else:
    print(S[:K] + "...")

Solution (Python):
k = int(input())
s = list(input())
if len(s) <= k:
    print(*s,sep="")
else:
    for i in range(k):
        print(s[i],end="")
    print("...")

Solution (Python):
K=int(input())
S=input()


if K<len(S):
  print(S[:K]+"...")
else:
  print(S)

Solution (Python):
K = int(input())
S = input()
T = len(S)
if T <= K:
  print(str(S))
else:
  print("{}...".format(S[:K]))

Solution (Python):
K=int(input())
S=input()

if len(S)>K:
  print(S[:K]+"...")
else:
  print(S[:])

Solution (Python):
n = int(input())

m = input()

o = len(m)

if o <= n:
  print(m)
elif o > n:
  print(m[0:n],'...',sep='')

Solution (Python):
import sys
int1 = lambda x: int(x) - 1
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
sys.setrecursionlimit(500000)

K = int(readline())
S = readline().decode().rstrip()

if len(S) <= K:
    print(S)
else:
    print(S[:K] + '...')

Solution (Python):
K = int(input())
S = input()

s = int(len(S))
tmp = []

if s <= K:
    print(S)
else:
    for i in range(K):
        tmp.append(S[i])
    tmp.append("...")


print("".join(map(str, tmp)))

Solution (Python):
K=int(input())
S=input()
list(S)
if len(S)<=K:
    print(S)
else:
    print(S[:K]+"...")

Solution (Python):
K=int(input())
S=str(input())
if len(S)<=K:
  print(S)
else:
  b=""
  for i in range(K):
    b+=S[i]
  print(b+"...")

Solution (Python):
import sys

val = input()
input_str = input()
 
if 0 > int(val) or int(val) > 100:
    sys.exit()
if 0 > len(input_str) or len(input_str) > 100:
    sys.exit()


if int(val) >= len(input_str):
    print(input_str)
else:
    new_str = input_str[0:int(val)]
    print(new_str + '...')

Solution (Python):
K = int(input(''))
S = input("")
if len(S) > K:
    print(S[0:K]+"...")
else:
    print(S)

Solution (Python):
import sys
input = sys.stdin.readline
def main():
    K = int(input())
    S = input().rstrip()
    if len(S) <= K:
        print(S)
    else:
        print(S[:K]+"...")
if __name__ == "__main__":
    main()

Solution (Python):
from sys import stdin

K = int(stdin.readline().rstrip())
S = stdin.readline().rstrip()


if len(S) <= K:
    print(S)
else :
    print(S[:K]+"...")

Solution (Python):
k=int(input())
s=input()
if len(s)>k:s=s[:k]+"..."
print(s)

Solution (Python):
K = int(input())
S = input().strip()
if len(S) <= K:
    print(S)
else:
    print(S[:-(len(S)-K)]+"...")

Solution (Python):
K = int(input())
S = input()

if len(S) > K:

    for i in range(0,K):

        print(S[i], end="")
    
    print("...")

else:

    print(S)

Solution (Python):
import numpy as np
k = int(input())
s = input()
if len(s) <= k:
  print(s)
else:
  print("{}...".format(s[:k]))

Solution (Python):



K=int(input())
S=input()

ans=S
if len(S)>K:
    ans=S[:K]+"..."

print(ans)

Solution (Python):
K = int(input())
S = input()
if len(S) <= K:
  print(S)
else:
  print(S[:K] + "...")

Solution (Python):
K=int(input())
S=input()

if len(S)<=K:
    print(S)
else:
    text=S[0:K]
    text=text+"..."
    print(text)

Solution (Python):
a=input()
b=input()

a=int(a)

if len(b) <= a:
	print(b)

else:
	b2=list(b)
	del b2[a:]
	b3="".join(b2)
	b4=b3+"..."
	print(b4)

Solution (Python):

k = int(input())
s = list(input())

if k >= len(s):
    print(''.join(s))
else:
    print(''.join(s[:k])+'...')

Solution (Python):
K = int(input())
S = input()

s = int(len(S))
tmp = []

if s <= K:
    print(S)
else:
    for i in range(K):
        tmp.append(S[i])
    tmp.append("...")


print("".join(map(str, tmp)))

Solution (Python):
K = int(input())
S = input()
if len(S) <= K:
    print(S)
else:
    print(S[0:K]+'...')

Solution (Python):
k = int(input())
s = input()
con1 = k >= 1 and k <= 100
con2 = len(s) >= 1 and len(s) <= 100
con3 = s.islower() == True and con2 == True
if con1 == True and con3 == True:
    if k < len(s):
        newstring = s[0:k] + "..."
        print(newstring)
    else:
        print(s)
else:
    print()

Solution (Python):
k = int(input())
s = input()
t = len(s)
if k >= t:
    print(s)
else:
    print(s[0:k] + "...")

Solution (Python):
K = int(input(''))
S = input("")
if len(S) > K:
    print(S[0:K]+"...")
else:
    print(S)

Solution (Python):
try:
  k=int(input())
  s=input()
  if len(s)>k:
      print(s[0:k]+"...")
  else:
      print(s)
except:
  pass

Solution (Python):
k = int(input())
s = input()

n = len(s)

if n <= k:
	print(s)
else:
	print(s[:k] + "...")

Solution (Python):
k = int(input())
s = input()

if len(s) > k:
  print(s[0:k] + "...")
else:
  print(s)

Solution (Python):
K=int(input())
S=input()
if len(S)>K:
    print(S[:K]+"...")
else:
    print(S)

Solution (Python):
K = int(input())
S = input()
ans = ""
if(len(S)>K):
    for i in range(K):
        ans = ans + S[i]
    ans = ans + "..."
else:
    ans = S

print(ans)

Solution (Python):
k = int(input())
s = input()

if len(s) <= k:
    print(s)
else:
    print(s[:k]+'...')

Solution (Python):
K = int(input())
S = input()

L = len(S)

if L <= K:
    print(S)
else:
    print(S[:K] + '...')

Solution (Python):

n=int(input())
s=input()
if len(s)<=n:
    print(s)
else:
    s=s[:n]+'...'
    print(s)

Solution (Python):









 
k = input()
s = input()


'''

'''
'''
n = input()
a = [int(input()) for i in range(n)]
'''
'''
n,m = map(int, input().split())
a = [list(map(int, input().split())) for _ in range(m)]
'''
 



if int(k)>=int(len(s)):
	print(s)
else:
    t=[s[0:int(k)]]
    t.append('...')
    u = ''.join(t)
    print(u)

Solution (Python):
K=int(input())
S=input()

n=len(S)

if n<=K:
    print(S)
else:
    for i in range(K):
        print(S[i],end="")
    print("...")

Solution (Python):
k = int(input())
s = input()
listS = list(s)

if len(s) <= k:
    print(s)
else:
    print(''.join(listS[0:k])+'...')

Solution (Python):
K = int(input())
S = input()

if len(S) <= K:
    print(S)
else:
    print(f"{S[:K]}...")

Solution (Python):
in_str = input()
in_str2 = input()

if (not in_str.isnumeric()) :
    print("error: 1st arg must be integer")
    exit()

num = int(in_str)
str = in_str2
str_len = len(in_str2)

if num > 100 :
    print("error: 1st arg must be under 100")
    exit()
if str_len> 100 :
    print("error: size of 2nd arg must be under 100")
    exit()

if num >= str_len :
    print(str)
else :
    print(str[0:num] + "...")

Solution (Python):
k = int(input())
s = list(input())
if k >= len(s):
  print(''.join(s))
else:
  l = []
  for i in range(k):
    l.append(s[i])
  l.append('...')
  m = ''.join(l)
  print(m)

Solution (Python):
k=int(input())
s=input()
if len(s)<=k:
    print(s)
else:
    print(s[0:k]+"...")

Solution (Python):
import sys

def S():
	return sys.stdin.readline().rstrip()

def I():
	return int(sys.stdin.readline().rstrip())

def main():
	K = I()
	word = S()
	if len(word) <= K:
		print(word)
	else:
		print(word[:K] + "...")

if __name__ == "__main__":
	main()

Solution (Python):
def tripledots(K: int, S: str)->str:
    if len(S) <= K:
        return S
    return S[:K] + '...'


if __name__ == "__main__":
    K = int(input())
    S = input()
    ans = tripledots(K, S)
    print(ans)

Solution (Python):
K = int(input())
S = input()
print(S if len(S) <= K else S[:K]+"...")

Solution (Python):
k = int(input())
s = []
s = str(input())
if len(s)<= k:
    print(s)
else:
    print(s[0:k]+'...')

Solution (Python):
k = int(input())
s = input()

if len(s) <= k:
    print(s)
else :
    t = s[:k]
    t = t + '...'
    print(t)

Solution (Python):
K = int(input())
S = input()
if len(S) <= K:
    print(S)
else:
    print(S[:K]+"...")

Solution (Python):
K = int(input())
N = input()

if len(N) <= K:
  print(N)
else:
  print(N[:K] + '...')

Solution (Python):
k = int(input())
s = list(str(input()))
if len(s) <= k:
    print(''.join(s))
else:
    ln = s[:k]
    ln.append('.')
    ln.append('.')
    ln.append('.')
    print(''.join(ln))

Solution (Python):
k = int(input())
s = str(input())

if len(s) <= k:
    print(s)
else:
    print(s[:k] + '...')

Solution (Python):
k = int(input())
s = list(input())

if len(s)>k:
    print((''.join(s[0:k]))+'...')
else:
    print(''.join(s))

Solution (Python):
x = '...'
K = int(input())
S = input()
ans = S
if len(S) > K:
    ans = S[:K] + x
print(ans)

Solution (Python):
i = int(input())

s = input()

if len(s) > i:
    print(s[:i] + '...')
else:
    print(s)

Solution (Python):
k = int(input())
s = input()

if len(s) <= k:
    print(s)
else:
    list(s)
    
    print(s[:k]+'...')

Solution (Python):
k = int(input())
s  = input()
if  len(s)<=k:
 print(s)
else:
 print(s[:k]+'...')

Solution (Python):
K = int(input())
S = input()

if len(S)<=K:
  print(S)
else:
  print(S[:K]+"...")

Solution (Python):
k = int(input())
n = input()
if len(n)<=k:
    print(n)
else:
    N = n[:k]
    print('{}...'.format(N))

Solution (Python):
k=int(input())
s=input()
if len(s)<=k:
    print(s)
else:
    print(s[:k]+'...')

Solution (Python):
k = int(input())
s = input()

if k >= len(s):
    print(s)

else:
    s = s[:k] + "..."
    print(s)

Solution (Python):
K = int(input())
S = input()
 
if K >= len(S):
  print(S)
else:
  print(S[:K] + "...")

Solution (Python):
K=int(input())
S=input()
D=[]
if len(S)<=K:
  print(S)
else:
  for i in range(K):
    D.append(S[i])
  D.append("...")
  P=''.join(D)  
  print(P)

Solution (Python):
k = int(input())
s = input()

if k >= len(s):
    print(s)
else:
    print(s[:k] + "...")

Solution (Python):
k = int(input())
s = input()
count = len(s)
if count <= k:
    print(s)
else:
    print("{}...".format(s[:k]))

Solution (Python):
K = int(input())
S = list(input())

if len(S) > K:
  print("".join(S[:K])+"...")
else:
  print("".join(S))

Solution (Python):
def cal():
    k = int(input())
    string = input()
    if len(string) <= k:
        print(string)
    else:
        list1 = list(string)
        for i in range(k):
            print(list1[i], end='')
        print("...")

cal()

Solution (Python):
string_list = [input() for i in range(2)]

if int(string_list[0]) >= len(str(string_list[1])):
    print(string_list[1])
else:
    print(str(string_list[1])[: int(string_list[0])] + "...")

Solution (Python):
k = int(input())
s = input()
if len(s) > k:
    print(s[:k] + "...")
else:
    print(s)

Solution (Python):
s=[]
k=int(input())
s=list(input())

if  len(s)>k:
    for i in range(k):
        print(s[i], end="")
    print("...")
else:
    print(''.join(s))

Solution (Python):
K=int(input())
S=input()

if len(S) <= K:
  print(S)
else:
  print(S[0:K]+'...')

Solution (Python):
k=int(input())
s=input()

if(len(s)<=k):
    print(s)
else:
    print(s[:k]+"...")

Solution (Python):
k = int(input())
s = input()

if len(s) <= k:
  print(s)
else:
  print(s[0:k] + '...')

Solution (Python):
k = int(input())
s = input()

if len(s) <= k:
    print(s)
else:
    ans = s[:k] + "..."
    print(ans)

Solution (Python):
k = int(input())


s = input()



if len(s) > k:
  new_s = s[0:k] + "..."
  print(new_s)
else:
  print(s)

Solution (Python):
k = int(input())
s = input()
if len(s) <= k:
    print(s)
elif len(s) > k:
    print(s[:k] + "...")

Solution (Python):
k = int(input())
s = input()
l = len(s)
if l <= k:
    print(s)
else:
    for i in range(k):
        print(s[i], end="")
    print("...")

Solution (Python):
K=int(input())
S=input()
if len(S)<=K:
  print(S)
else:
  print(S[:K]+'...')

Solution (Python):
k=int(input())
s=input()
if len(s)<=k:
    print(s)
else:
    print(s[:k]+"...")

Solution (Python):
K = int(input())
S = input()

if len(S) > K:
    print(S[:K] + "...")
else:
    print(S)

Solution (Python):
n = int(input())
k = input()
num = len(k)

if(num <= n):
    print(k)
else:
    print(k[:n] + '...')

Solution (Python):
K = int(input())
S = list(input())
if len(S) <= K:
	word = ""
	for a in S:
		word += a
	print(word)
else:
	i = 0
	word =  ""
	while i < K:
		word += S[i]
		i += 1
	word += "..."
	print(word)

Solution (Python):
k = int(input())
s = list(input())

S = len(s)
if S <= k:
    mojiretu = ''
    for x in s:
        mojiretu += x
    print(mojiretu)
else:
    T =s[:-(S-k)]
    mojiretu = ''
    for x in T:
        mojiretu += x
    print(mojiretu + '...')

Solution (Python):
k = int(input())
S = input()
B = " "
l = len(S)
if l <= k:
    print(S)
else:
    B = S[0:k] + "..."
    print(B)

Solution (Python):
K = int(input())
S = input()

if len(S) <= K:
	print(S)
else:
	S = list(S)
	S = S[:K]
	ans = ''
	ans = ans.join(S)
	ans += '...'
	print(ans)

Solution (Python):
n = int(input())
m = list(map(str,input()))
if len(m) > n:
    a = m[:n]
    print(''.join(a)+'...')
else:
    for i in m:
        print(i,end='')

Solution (Python):
k = int(input())
s = input()
l = len(s)
if l<=k:
  print(s)
else:
  print(s[0:k] + "...")

Solution (Python):
k = int(input())
s = input()
if len(s) > k:
    print(s[:k] + "...")
else:
    print(s)

Solution (Python):
k = int(input())
s = str(input())

if k >= len(s):
    ans = s
else:
    rest = len(s) - k
    ans = s[0:k] + '...'
print(ans)

Solution (Python):
K = int(input())
S = input()
if len(S) <= K:
    print(S)
else:
    print(S[0:K]+'...')

Solution (Python):
k = int(input())
s = input()
if len(s) > k:
  print(s[:-(len(s)-k)] + '...')
else:
  print(s)

Solution (Python):
k = int(input())
s = input()
n = len(s)

if k >= n:
  print(s)
else:
  print(s[:k] + "...")

Solution (Python):
K = int(input())
S = str(input())

if len(S)>K :
  print(S[:K]+"...")
else :
  print(S)

Solution (Python):
k=int(input())
s=input()
print(s[:k]+"...") if len(s)>k else print(s)

Solution (Python):
K = int(input())
S = input()
if len(S) <=  K:
    print(S)
else:
    print(S[:K]+"...")

Solution (Python):
K = int(input())
S = list(input())

if len(S) <= K:
    ans = "".join(S)
    print(ans)
else:
    ans_list = S[0:K]
    ans = "".join(ans_list)
    print(ans+'...')

Solution (Python):
k = int(input())
s = input()

if len(s) <= k:
    print(s)
else:
    s = s[:k] + "..."
    print(s)

Solution (Python):
k = input()
k = int(k)
s = input()
if len(s) <= k:
    print(str(s))
else:
    s = s[:k]
    print(str(s)+"...")

Solution (Python):
K = int(input())
S = input()
L = len(S)
if (L <= K):
    print(S)
else:
    print(S[:K] + "...")

Solution (Python):
K=input()
S=list(input())
answer_str=S[0]
if len(S) <= int(K) :

  for i in range(len(S)-1):
    answer_str += S[i+1] 
  
else :
  for i in range(int(K)-1):
    answer_str += S[i+1] 
  answer_str += "..."
print(str(answer_str))

Solution (Python):
K = int(input())
S = input()

if len(S) <= K:
    print(S)
else:
    print(S[0:K]+"...")

Solution (Python):
n = int(input())
s = input()
if len(s)<=n:
    print(s)
elif len(s)>n:
    print(s[0:n]+"...")

Solution (Python):
k = int(input())
s = input()

if len(s) > k:
    print(s[0:k] + '...')
else:
    print(s)

Solution (Python):
k = int(input())
s = str(input())
n = len(s) - k
print(s[:k]+'...' if n>0 else s)

Solution (Python):

K = int(input())
S = input()

if(K>=len(S)):
    print(S)
else:
    print(S[0:K]+"...")

Solution (Python):
K=int(input())
S=input()

if(len(S)<=K):
  print(S)
else:
  print(S[:K]+'...')

Solution (Python):
k = int(input())
s = input()
if len(s)<=k:
    print(s)
else:
    print(s[:k]+'...')

Solution (Python):
k = int(input())
s = input()
if(len(s) <= k):
    print(s)
else:
    print(s[:k]+"...")

Solution (Python):


def main():
    k = int(input().strip())
    s = input().strip()
    if len(s) <= k:
        print(s)
    elif len(s) > k:
        print(s[:k]+"...")

if __name__=="__main__":
    main()

Solution (Python):
K = int(input())
S = input()
a = len(S)

if a <= K:
    print(S)
else:
    print(S[0:K]+"...")

Solution (Python):
import sys
k =int(input())
s =list(str(input()))
s_s = len(s)
if k >= s_s:
  print("".join(map(str,s)))
  sys.exit()
ans = s[:k]
ans = "".join(map(str,ans))
ans = ans + '...'
print(ans)

Solution (Python):
import bisect
import copy
import heapq
import sys
import itertools
import math
import queue
input = sys.stdin.readline
sys.setrecursionlimit(1000000)


def read_values(): return map(int, input().split())
def read_index(): return map(lambda x: int(x) - 1, input().split())
def read_list(): return list(read_values())
def read_lists(N): return [read_list() for n in range(N)]
def init_dp1(init, N): return [init for _ in range(N)]
def init_dp2(init, N, M): return [[init for _ in range(M)] for _ in range(N)]


def main():
    K = int(input())
    S = input().strip()
    if len(S) <= K:
        print(S)
    else:
        print(S[:K] + "...")


if __name__ == "__main__":
    main()

Solution (Python):


def LI():
    return list(map(int, input().split()))


K = int(input())
S = input()


def main():
    n = len(S)
    ans = S
    if n > K:
        ans = S[:K] + "..."
    print(ans)


if __name__ == "__main__":
    main()

Solution (Python):
K=int(input(""))
S=list(input(""))

A=len(S)
B=()

if A <= K:
      print (''.join(map(str, S)))
else:
      B=(S[0:K])
      B.append("...")
      print (''.join(map(str, B)))

Solution (Python):
k = int(input())
s = input()

length = len(s)
if length <= k:
    print(s)
else:
    print(s[:k] + "...")

Solution (Python):
K=int(input())
S=input()
if len(S)<=K:
    print(S)
else:
    print(S[:K]+'...')

Solution (Python):
import sys
k =int(input())
s =list(str(input()))
s_s = len(s)
if k >= s_s:
  print("".join(map(str,s)))
  sys.exit()
ans = s[:k]
ans = "".join(map(str,ans))
ans = ans + '...'
print(ans)

Solution (Python):

import numpy as np
from functools import *
import sys
sys.setrecursionlimit(100000)

def acinput():
    return list(map(int, input().split(" ")))

K=int(input())
S=input()

if len(S)>K:
    print(S[:K]+"...")
else:
    print(S)

Solution (Python):
k = int(input())
s = input()
print(s if len(s)<=k else s[:k:]+'...')

Solution (Python):
k = int(input())
s = input()

s_length = int(len(s))

if s_length <= k:
    print(s)
elif s_length > k:
    print(s[:k]+"...")

Solution (Python):
import math

import sys

def Next(): return input()
def NextInt(): return int(Next())
def NextInts(): return map(int,input().split())
def Nexts(): return map(str,input().split())
def NextIntList(): return list(map(int,input().split()))
def RowInts(n): return [input() for i in range(n)]


n = NextInt()
s = input()
if len(s) > n:
    s = s[:n] + "..."
print(s)

Solution (Python):
K = int(input())
S = input()

if K < len(S):
    print(f"{S[:K]}...")
else:
    print(S)

Solution (Python):
k = int(input())
s = input()
if len(s) <= k:
    print(s)
else:
    print(s[:k]+'...')

Solution (Python):
k = int(input())
s = input()

if len(s) <= k:
    ans = s
else:
    ans = s[:k] + '...'

print(ans)

Solution (Python):
K=int(input())
S=input()
if(len(S)>K):
  X=S[:K]+'...'
else:
  X=S[:K]
print(X)

Solution (Python):
K,S = int(input()),input()
if len(S) > K:
    print(S[:K] + "...")
else:
    print(S)

Solution (Python):
K = int(input())
S = input()

if len(S) <= K:
    print(S)
else:
    for i in range(K):
        print(S[i], end="")
    print("...")

Solution (Python):
K = int(input())
S = str(input())

if(len(S) <= K):
    print(S)
else:
    S = S[0:K]   
    S += '...'
    print(S)

Solution (Python):
K=int(input())
S=input()

B = list(S)

L = len(S)


if L <= K :
	print(S)
else:
	B=B[0:K]
	B= ''.join(B)
	print(B+'...')

Solution (Python):
K = int(input())
S = str(input())

if len(S) <= K:
    print(S)
else:
    print(S[:K] + "...")

Solution (Python):
k = int(input())
s = input()

l = len(s)

if l <= k:
    print(s)
else:
    print(s[:k]+"...")

Solution (Python):

K = int(input())
S = input()

count = len(S)

if count <= K:
    print(S)
else:
    print(S[:K]+'...')

Solution (Python):
k=int(input())
s=input()
ans=0

for i in range(len(s)):
    if i == k :
        ans = i
        break

if ans != 0 :
    print(s[:i]+'...')
else :
    print(s)

Solution (Python):
K = int(input())
S = input()

if len(S) <= K:
    print(S)
else:
    print(S[:K],'...', sep="")

Solution (Python):
import sys
sys.setrecursionlimit(300000)

def I(): return int(sys.stdin.readline())
def MI(): return map(int, sys.stdin.readline().split())
def LMI(): return list(map(int, sys.stdin.readline().split()))
MOD = 10 ** 9 + 7
INF = float('inf')


K = I()
S = input()

if len(S) <= K:
    print(S)
else:
    print(S[:K] + '...')

Solution (Python):
k = int(input())
s = input()
if len(s) <= k:
  print(s)
else:
  print("{}...".format(s[:k]))

Solution (Python):
n=int(input())
s=input()
score=''
if n>=len(s):
	print(s)
else:
	for i in range(n):
		score+=s[i]
	print("{}...".format(score))

Solution (Python):
import sys
readline = sys.stdin.buffer.readline
k =int(readline().rstrip().decode())
n = readline().rstrip().decode()
if len(n) > k:
  print(n[:k] + "...")
else:
  print(n)

Solution (Python):
k = int(input())
s = input()
n = len(list(s))
if n <= k:
    print(s)
else:
    t = s[:k]+"..."
    print(t)

Solution (Python):
K = int(input())
S = input()
if len(S) <= K:
    print(S)
elif len(S) > K:
    for i in range(K + 1):
        if i == K:
            print('...')
        else:
            print(S[i], end = '')

Solution (Python):
K = int(input())
S = input()

if len(S)<= K:
    print(S)
else:
    S2 = S[0:K]+"..."
    print(S2)

Solution (Python):
k = int(input())
s = list(input())

if len(s) <= k:
    print("".join(map(str, s)))
else:
    b = list(s[0:k])
    ans = map(str, b)
    aa = "".join(b)
    print(aa+"...")

Solution (Python):
K = int(input())
S = input()

if len(S) <= K:
    print(S)
    
elif len(S) >= K:
    print(S[:K] + '...')

Solution (Python):
K = int(input())
S = str(input())

if len(S) <= K:
  print(S)
else:
  print(S[:K] + "...")

Solution (Python):
K = int(input())
S = input()

if len(S) <= K:
    print(S)
else:
    print(S[:K] + "...")

Solution (Python):
k = int(input())
s = input()
if len(s) <= k:
    print(s)
else:
    print(s[:k] + '...')

Solution (Python):
k = int(input())
s = input()

a = len(s)

if a <= k:
    print(s)
else:
    t = s[0:k]+"..."
    print(t)

Solution (Python):
K = int(input())
S = input()
if len(S) <= K:
    print(S)
else:
    print(S[:K] + '...')

Solution (Python):
K = int(input())
S = input()
if len(S) <= K:
    print(S)
else:
    str = S[:K]+'...'
    print(str)

Solution (Python):
import bisect,collections,copy,heapq,itertools,math,numpy,string
import sys
def S(): return sys.stdin.readline().rstrip()
def I(): return int(sys.stdin.readline().rstrip())
def SS(): return map(str,sys.stdin.readline().rstrip().split())
def II(): return map(int,sys.stdin.readline().rstrip().split())
def LI(): return list(map(int,sys.stdin.readline().rstrip().split()))
def LS(): return list(sys.stdin.readline().rstrip().split())

K = I()
s = S()

if len(s) <= K:
  print(s)
else:
  print(s[0:K]+"...")

Solution (Python):
k = int(input())
s = list(input())

if len(s) <= k:
    print("".join(s))
else:
    print("".join(s[:k]) +"...")

Solution (Python):
K = int(input())
S = input()

s = len(S)

if (s<=K):
    print(S)
else:
    print(S[0:K]+"...")

Solution (Python):
K = int(input())
S = input()

if K >= len(S):
  print(S)
else:
  print(S[:K] + "...")

Solution (Python):
k=int(input()) 
s=str(input()) 

if len(s)<=k:
  print(s[:k])
else:
  print(s[:k]+"...")

Solution (Python):
limit = int(input())
original = input()
if(int(len(original))>limit):
  print(original[0:limit]+ "..." )
else:
  print(original)

Solution (Python):
K=int(input())
S=input()
if len(S)<=K:
    print(S)
else:
    print(S[0:K]+'...')

Solution (Python):
k = int(input())
s = input()

if len(s) <= k:
    print(s)
else:
    print(s[0:k], end='...')

Solution (Python):
K = int(input())
S = input()
if len(S) > K:
    print(S[:K]+"...")
else:
    print(S)

Solution (Python):
k = int(input())
s = input()
slen = len(s)

if(slen>k):
    str=s[0:k]+"..."
else:
    str=s

print(str)