Advent of Code Not Quite Lisp by Sp3000

while 1:
 i=a=n=0
 for c in raw_input():n+=cmp(c,"(~");i+=1>a;a+=n>0
 print i

Note that non-ascii characters in the above source code will be escaped (such as \x9f).

download

return to the top page