#include<iostream>
#include<cstring>
using namespace std;
int main()
{
	char str[100];
	int i,j,l;
	cin>>str;
	l=strlen(str);
	for(i=0;i<l;i++)
	{
		for(j=0;j<l;j++)
		{
			if(i==j||(i+j==l-1))
				cout<<str[j];
			else
				cout<<" ";
		}
		cout<<"\n";
	}
	return 0;
}