Wonderful Multisets by tester

x=lambda a:+(len(a)<=2*sum(i if i<2 else x(i)for i in a))
while 1:print x(eval("".join(["0,","1,","[","],"]["01{}".find(c)]for c in raw_input()))[0])

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

To protect the system from spam, please input your favorite sport (hint: I believe its name must start with 'g', case insensitive)


return to the top page