Ad
  • Custom User Avatar

    Damn i always forget to use the return of the sorted method, thanks for the tip :)

  • Custom User Avatar

    A tip: you could just replace list with sorted to make it shorter
    sort = lambda x: ''.join(sorted(filter(str.isalpha, x)) + sorted(filter(str.isdigit, x)))

    And it's also sorting less element