C programming examples with output
Pattern
Program
#include<stdio.h>
#include<conio.h>
void main()
{
char i,j;
clrscr();
for(i='E';i>='A';i--)
{
for(j='E';j>='A';j--)
{
printf("%c",i);
}
printf("\n");
}
getch();
}
Output:
EEEEE
DDDDD
CCCCC
BBBBB
AAAAA
Pattern
Program
#include<stdio.h>
#include<conio.h>
void main()
{
char i,j;
clrscr();
for(i='E';i>='A';i--)
{
for(j='E';j>='A';j--)
{
printf("%c",i);
}
printf("\n");
}
getch();
}
Output:
EEEEE
DDDDD
CCCCC
BBBBB
AAAAA
0 komentar:
Post a Comment