Created
March 31, 2014 08:48
-
-
Save cristobal/9888101 to your computer and use it in GitHub Desktop.
Do you want to script in some random lang, just change the langs list to your choice…
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 | |
from random import shuffle | |
def main(): | |
langs = ["coffe", "node", "lua", "python", "ruby", "php"] | |
scores = {} | |
for lang in langs: | |
scores[lang] = 0 | |
while True: | |
shuffle(langs) | |
scores[langs[0]] += 1 | |
if scores[langs[0]] == 3: | |
lang = langs[0] | |
break | |
print "You will now code your next script in `%s`" % lang | |
pass | |
if __name__ == "__main__": | |
main() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment