Created
October 28, 2010 14:50
-
-
Save fish2000/651488 to your computer and use it in GitHub Desktop.
my solution to the 'prove you are a programmer' question that hirelite.com posed to me when registering
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/env python | |
# encoding: utf-8 | |
def hirelite(i): | |
if not i % 4: | |
if not i % 7: | |
return "rickroll" | |
return "rick" | |
if not i % 7: | |
return "roll" | |
return i | |
def main(): | |
for i in xrange(1, 201): | |
print hirelite(i) | |
if __name__ == '__main__': | |
main() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment