WRITE A PROGRAM TO PRINT THE FOLLOWING OUTPUTS USING FOR
LOOPS.
A) * B) *****
*** * *
***** * *
*****
Answer Posted / vutukuru
#include<stdio.h>
main()
{
int i,j,n=5;
clrscr();
for(i=0;i<n-4;i++)
{
printf("*");
}
printf("\n");
for(i=0;i<n-2;i++)
{
printf("*");
}
printf("\n");
for(i=0;i<n;i++)
{
printf("*");
}
getch();
}
| Is This Answer Correct ? | 18 Yes | 12 No |
Post New Answer View All Answers
How do you write a program which produces its own source code as output?
Explain argument and its types.
please can any one suggest me best useful video tutorials on c i am science graduate.please help me.u can email me to sas29@in.com
i have a written test for microland please give me test pattern
By using C language input a date into it and if it is right?
What is a const pointer?
Explain what is operator promotion?
What happens if a header file is included twice?
What is optimization in c?
How do you determine a file’s attributes?
What is table lookup in c?
In C language, a variable name cannot contain?
How does normalization of huge pointer works?
What is difference between union and structure in c?
What is a keyword?