import java.util.*; 
class Main 
{
public static void main(String args[]) 
{
Scanner sc = new Scanner(System.in); 
int n = Integer.parseInt(sc.nextLine()); 
String s = sc.nextLine(); 
int l= s.length(); 
if(l<=n) 
{
System.out.print(s);
} 
else 
{ 
System.out.print((s.substring(0,n))+"...");    
}
} 
} import java.util.*; util.* java class Main 
{
public static void main(String args[]) 
{
Scanner sc = new Scanner(System.in); 
int n = Integer.parseInt(sc.nextLine()); 
String s = sc.nextLine(); 
int l= s.length(); 
if(l<=n) 
{
System.out.print(s);
} 
else 
{ 
System.out.print((s.substring(0,n))+"...");    
}
} 
} Main public static void main(String args[]) 
{
Scanner sc = new Scanner(System.in); 
int n = Integer.parseInt(sc.nextLine()); 
String s = sc.nextLine(); 
int l= s.length(); 
if(l<=n) 
{
System.out.print(s);
} 
else 
{ 
System.out.print((s.substring(0,n))+"...");    
}
} main {
Scanner sc = new Scanner(System.in); 
int n = Integer.parseInt(sc.nextLine()); 
String s = sc.nextLine(); 
int l= s.length(); 
if(l<=n) 
{
System.out.print(s);
} 
else 
{ 
System.out.print((s.substring(0,n))+"...");    
}
} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = Integer.parseInt(sc.nextLine()); n Integer.parseInt(sc.nextLine()) Integer.parseInt Integer sc.nextLine() sc.nextLine sc String s = sc.nextLine(); s sc.nextLine() sc.nextLine sc int l= s.length(); l s.length() s.length s if(l<=n) 
{
System.out.print(s);
} 
else 
{ 
System.out.print((s.substring(0,n))+"...");    
} l<=n l n {
System.out.print(s);
} System.out.print(s) System.out.print System.out System System.out s { 
System.out.print((s.substring(0,n))+"...");    
} System.out.print((s.substring(0,n))+"...") System.out.print System.out System System.out (s.substring(0,n))+"..." (s.substring(0,n)) s.substring s 0 n "..." String args[] args
import java.util.*; 
class Main 
{
public static void main(String args[]) 
{
Scanner sc = new Scanner(System.in); 
int n = Integer.parseInt(sc.nextLine()); 
String s = sc.nextLine(); 
int l= s.length(); 
if(l<=n) 
{
System.out.print(s);
} 
else 
{ 
System.out.print((s.substring(0,n))+"...");    
}
} 
}