Created
September 3, 2018 14:12
-
-
Save dnbaker/67703faca3ddb938eebc64634a92ead5 to your computer and use it in GitHub Desktop.
Corrupt your text
This file contains 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
import sys | |
import random | |
if __name__ == "__main__": | |
for line in sys.stdin if len(sys.argv) < 2 else open(sys.argv[1]): | |
for char in line: | |
if char.isalpha(): | |
sys.stderr.write(char if random.choice([0,1]) else chr(ord(char) ^ 32)) | |
else: | |
sys.stderr.write(char) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment