You can download this code by clicking the button below.
This code is now available for download.
This function takes a list of strings as input and returns a list sorted by the length of the strings.
Technology Stack : String list, sorting
Code Type : Function
Code Difficulty : Beginner
def sorted_names_by_length(names):
return sorted(names, key=len)