Musings of a programmer, musician, photographer, and Christian.
Python Fun - Onliners
I’ve not done a ton of programming in Python for a while, but I still
do like the language. I also like trying to do things in one line
(ok, one statement), just because it’s a bit more difficult :). These
are pretty old, but I used to keep these in my email signature line…
#this one really only works if your terminal window is 80 wideimportos;map(lambdai:os.write(1,chr(reduce(lambda(z,t),o:abs(z*z)>4and(6,t)or(z*z+o,t+1),[(i%80*.04875-2.6+i/80*2.8j/26-1.4j,65)]*31))),range(2080))