Created
October 26, 2011 14:55
-
-
Save mwchambers/1316597 to your computer and use it in GitHub Desktop.
Wake up neo.. the matrix
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
#/usr/bin/python | |
import time | |
import sys | |
import os | |
lines=[ | |
"Wake up Neo ...", | |
"The matrix has you", | |
"Follow the white rabbit ...", | |
"Knock knock." | |
] | |
os.system("clear") | |
#GREEN = '\033[92m' | |
GREEN = '\033[22;32m' | |
ENDC = '\033[0m' | |
print GREEN, | |
for line in lines: | |
words = line.split() | |
for word in words: | |
for c in list(word): | |
sys.stdout.write(c) | |
sys.stdout.flush() | |
time.sleep(0.15) | |
sys.stdout.write(" ") | |
sys.stdout.flush() | |
time.sleep(0.7) | |
if line.startswith("Follow"): | |
time.sleep(2) | |
if not line.startswith("Knock"): | |
os.system("clear") | |
print ENDC | |
time.sleep(300) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment