i=513 while i: a,c,j='',64,i-257;i-=1 while c:a+=' #'[j%2];j=((j%2*2+1)*j+j%2)/2;c-=1 print a+'|'