You are viewing a single comment's thread. Return to all comments →
num_odd,num_even,low,cap="","","","" for i in range(len(s)): if s[i].lower() == s[i]: if s[i].isdigit(): if int(s[i]) % 2: num_odd += (s[i]) else: num_even += (s[i]) else: low += s[i] else: cap += s[i] s = low+cap+str(num_odd)+str(num_even) print(s)
Seems like cookies are disabled on this browser, please enable them to open this website
ginortS
You are viewing a single comment's thread. Return to all comments →