Sierpinski Carpet by recursive

b="::",
exec"o=[r*3for r in b];b=o+[r+' '*len(r)+r for r in b]+o;"*input()
print"\n".join(b)

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

download

return top