Write a program, input a letter in upper case, then print as follows: (input E): ABCDE in the middle is aligned as a column.
#include <stdio.h>
int main()
{
int i,j,k,l;
char a='A';
for(i=1;i<=5;i++){
for(j=1;j<=5-i;j++)
printf(" ");
for(k=1;k<=i;k++)
printf("%c",a++);
a--;
for(l=k-2;l>0;l--){
a--;
printf("%c",a);}
printf("\n");
}
return 0;
}