Generation

generate functionSun, 20 Nov 2022

Python Program to arrange sorted alpha numeric string

def arrangeString(str): # split() returns list of strings # separated by given separator. temp = str.split(' ') print(temp) # now sort temp list temp.sort() # join list elements to string res = ' '.join(temp) print(res) arrangeString('H31 10 23 P')

Want to kickstart your project?Use the new AI Studio to create your code