s=raw_input() j=len(s);exec'j-=1;print" "*j+" ".join(s[j:])+" "*j;'*j