Hofstadter Q sequence by recursive

a,b=Q=1,1
exec"print a;a,b=b,Q[-b]+Q[-a];Q+=b,;"*300

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

download

return to the top page