String Sorting by Length

  • Share this:

Code introduction


Sorts a list of strings by their length


Technology Stack : Sorting

Code Type : Function

Code Difficulty :


                
                    
def string_sort_by_length(words):
    return sorted(words, key=len)                
              
Tags: