You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
12 lines
213 B
12 lines
213 B
3 years ago
|
import sys
|
||
|
|
||
|
phrase = sys.argv[1]
|
||
|
for word in phrase.split():
|
||
|
print('{initial}{size}{final} '.format(
|
||
|
initial=word[0],
|
||
|
final=word[-1],
|
||
|
size=max(len(word)-2, 0)
|
||
|
), end='')
|
||
|
|
||
|
print('')
|