-
-
Save mattdennewitz/4287419 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import sys | |
last = '' | |
punc = ',' | |
while True: | |
c = sys.stdin.read(1) | |
if c: | |
if c in punc or c.isalpha() and not last.isalpha() and last not in ('\'',): | |
sys.stdout.write(c.upper()) | |
last = c | |
else: | |
sys.stdout.write('\n') | |
break |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment