You are viewing a single comment's thread. Return to all comments →
import sys while True: line=sys.stdin.readline().strip() if not line: break Input=line.split(";") operation=Input[0] Type=Input[1] word=Input[2] if operation=="S": res="" for i in word: if i.isupper() and not res: res+=i.lower() elif i.isupper() and res: res+=" "+i.lower() elif i=="("or i==")": continue else: res+=i print(res) elif operation=="C": String=word.split() res=String[0].lower() if Type=="C": res=res.capitalize() for i in String[1:]: res+=i.capitalize() if Type=="M": res+="()" print(res)
Seems like cookies are disabled on this browser, please enable them to open this website
Camel Case 4
You are viewing a single comment's thread. Return to all comments →