Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
caps = not caps solution in Clear category for Caps Lock by flpo
def caps_lock(text: str) -> str:
def characters():
caps = False
for char in text:
if char == 'a':
caps = not caps
else:
yield char.upper() if caps else char
return ''.join(characters())
Dec. 13, 2018
Comments: