open System

let flip f a b = f b a
let read() = Console.ReadLine()

[<EntryPoint>]
let main _ =
    let s = read() |> int
    let k = read()
    if k.Length > s then k.Substring(0, s) + "..."
    else k
    |> printfn "%s"
    
    0 
