well this is not something that i would normally ask for but i\'m quite desperate. i\'ve been studying for my midterm exams and so i decided to solve some of the problems in the text book i came across this nice little question which asked to print the following patterns using the "for loop" and "printf("*")"
a.
*
**
***
****
*****
******
*******
********
*********
**********
b. is the mirror image of a
_________*
________**
_______***
______****
_____*****
____******
___*******
__********
_*********
********** (without the ________)
now the first was a peice of cake
#include
int main ()
{
int i;
int size=10, count=9;
for(count=9;count>=0;count--)
{
for (i=1;i<=size-count;i++)
{
printf("*");
}
printf("\\n");
}
return 0;
}
now i\'ve been trying to solve the second for over an hour and still havent come up with a viable solution.
so if anyone can help me, please do.
