Advertisement
nq1s788

1d (2a)

Feb 28th, 2024
681
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.15 KB | None | 0 0
  1. n = int(input())
  2. for i in range(n):
  3.     s = input()
  4.     if len(s) > 10:
  5.         print(s[0] + str(len(s) - 2) + s[-1])
  6.     else:
  7.         print(s)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement