Example & Tutorial understanding programming in easy ways.

Sort the string and convert it into the list in Python.

program:

s="Mystring"

print(sorted(s))

output:

['M', 'g', 'i', 'n', 'r', 's', 't', 'y']

Read More →