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