You are viewing a single comment's thread. Return to all comments →
def swap_case(s): result = "" for ele in s: if (ord(ele) in range(65, 92)): result += chr(ord(ele)+32) elif (ord(ele) in range(97, 123)): result += chr(ord(ele)-32) else: result += ele return result
Seems like cookies are disabled on this browser, please enable them to open this website
sWAP cASE
You are viewing a single comment's thread. Return to all comments →