c programs coding compile by mingW
Monday, 7 January 2013
Write a program which prints following sequence
#include<stdio.h>
void main()
{
int i,j,xy=70,a=70;
printf("ABCDEFGFEDCBA\n");
for(i=1;i<=6;i++)
{
for(j=65;j<=xy;j++)
printf("%c",j);
xy--;
for (j=1;j<=2*i-1;j++)
printf(" ");
for(j=65;j<=a;j++)
printf("%c",j);
a--;
printf("\n");
}
}
li
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment