Sorting String Characters by ASCII Values

  • Share this:

Code introduction


This function takes a string argument and returns a new string where the characters are sorted by their ASCII values.


Technology Stack : Built-in libraries: None

Code Type : String processing

Code Difficulty :


                
                    
def aord(st):
    return ''.join(sorted(st))