for n in range(256,-257,-1):o='';exec"o+=' #'[n%2];n=(n,3*n+1)[n%2]/2;"*64;print o+'|'