import Data.List
import Data.Bool

main = do
        k <- readLn :: IO Int
        s <- getLine
        putStrLn $ ans k s

ans :: Int -> String -> String
ans k s = if (length s) > k
          then take k s ++ "..."
          else s

