A C program to print the following pattern:
E
DE
CDE
BCDE
ABCDE
main()
{
int i,j,n;
printf("Enter the number of rows:");
scanf("%d",&n);
for(i=n;i>=1;i--)
{
for(j=i;j<=n;j++)
{
printf("%c",A+j-i);
}
printf("
");
}
getch();
}
Copyright (c) 2010 Computer Info.
Powered by Blogger
0 komentar:
Posting Komentar