4 ms·
I tend to abuse lambdas plus itertools/functools to write "obfuscated" Python for fun. For example... * FizzBuzz with no control-flow keywords: https://github.
by ubernostrum 8y ago
I tend to abuse lambdas plus itertools/functools to write "obfuscated" Python for fun. For example...
* FizzBuzz with no control-flow keywords: https://github.com/ubernostrum/interviewer-hell/blob/master/fizzbuzz/iterator.py https://github.com/ubernostrum/interviewer-hell/blob/master/...
* Detecting if a number is a perfect square as a one-line lambda: https://github.com/ubernostrum/interviewer-hell/blob/master/squares/odds.py https://github.com/ubernostrum/interviewer-hell/blob/master/...
- carapace 8y agoAh, those are great. I can't find it now but some daredevil wrote a Lisp interpreter in a single Python expression. A work of art.