#include<stdio.h>
#include<string.h>

int main()
{
char str[50];
char str2[50][50];
int lenstr;
int i,j;
char temp;

printf("Enter the string :\n");
scanf("%s",str);
lenstr = strlen(str);
if(lenstr %2 == 0)
{
    printf("The string length must be an odd length");

}
else
{
j = 0;
temp = 0;

for(i = 0;i<lenstr;i++)
    for(j = 0;j<lenstr;j++)
      str2[i][j] = ' '; 

  for(i = 0;i < lenstr;i++)
  {
      str2[i][i] = str[i];
      str2[i][lenstr- i -1] = str[i];
  }
/*
  for(i = lenstr; i!=0 ;i--)
  {
      j = lenstr;
      str2[i][j] =  str[temp];
      temp = temp + 1;
      j = j - 1;

  }
  */
      for(i = 0;i<lenstr;i++)
      {

        for(j = 0;j<lenstr;j++)
      {
          printf("%c",str2[i][j]);
      }
      printf("\n");
      }

}

return 0;}