does anyone know how todisplay the following using a for loop in my program
question:if n=5 where n is the ht of the pattern
*********
**** ****
*** ***
** **
* *
if n=4
*******
*** ***
** **
* *
SOLUTION I TRIED OUT IS
#include<stdio.h>
#include<conio.h>
void main()
{
int i,j;
for(i=1;i<=5;i++)
{
for(j=1;j<=5;j++)
{printf("*");
}
printf("\n");
}
getch();
}
pls suggest modifications if anyone knows how to display the correct solution.