#include <iostream.h>
#include <conio.h>
int main ()
{
int i, j;
for (i = 0; i <= 4; i++)
{
for (j = 0; j <= 5-i; j++)
cout<< " " ;
for (j = 5-i; j <= 5+i; j++)
cout<< "*" ;
cout<< endl;
}
for (i = 2; i <= 5; i++)
{
for (j = 0; j <= i; j++)
cout<< " " ;
for (j = i; j <= (10-i); j++)
cout<< "*" ;
cout<< endl;
}
return 0;
}
what do i and j stand for? im working on this but have 4 variables.
ReplyDeletei and j are counter variables used for loop iterations.
DeleteThaks
ReplyDeleteI’ve been searching for some decent stuff on the subject and haven't had any luck up until this point, You just got a new biggest fan!.. necklace charms
ReplyDelete