   program abc168b
      implicit none
      character(100)::s
      integer::k,i

         read *, k
         read *, s

         i=len_trim(s)
         if (i<=k) then
            print *, s
         else
            print *, s(1:k),'...'
         end if

   end program abc168b