Last active
August 29, 2015 14:03
-
-
Save paulproteus/1237524acb81a69ede66 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
➜ n_and_s cat gen.py | |
def to_n_and_s(i): | |
x = bin(i) | |
assert x.startswith('0b') | |
x = x[2:] | |
x = x.replace('1', 'n\n') | |
x = x.replace('0', 's\n') | |
x += 'c\n' | |
return x | |
for i in xrange(100000): | |
print to_n_and_s(i) | |
➜ n_and_s for input in `python gen.py` ; do | |
echo $input | python manage.py test | |
done | |
➜ n_and_s for input in `python gen.py` ; do | |
echo $input | python manage.py test | |
done | |
➜ n_and_s for input in `python gen.py` ; do | |
echo $input | python manage.py test | |
echo " ----------------------- " ; echo " USED: $input " ; echo " -------------------- " ; done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment