First of all, thank you for your answer.
I did as you told me. Here is the Python script I incorporated in my workflow (I kept only the ASC sorting) :
#coding: utf-8
import sys
my_list = input
#print('\n'.join(sorted(my_list)))
#print('=' * 5)
print('\n'.join(sorted(my_list, key=len))) #Line 10
print('=' * 5)
#print('\n'.join(reversed(sorted(my_list, key=len))))
#print('=' * 5)
But I get the following message :
Line 10: TypeError: 'builtin_function_or_method' object is not iterable
Did I do something wrong ?
Thanks again