what is the code for getting the output as
*
**
***
Answer Posted / anvesh
main()
{
printf("*\n**\n***);
}
OR
main()
{
int n,i;
while(n<3)
{
i=0;
while(i<=n)
{printf("*");i++;}
printf("\n); n++;
}
Is This Answer Correct ? | 4 Yes | 3 No |
Post New Answer View All Answers
Explain what is the best way to comment out a section of code that contains comments?
in case any function return float value we must declare a) the function must be declared as 'float' in main() as well b) the function automatically returned float values c) function before declared 'float' keyword d) all the above
Explain how can I open a file so that other programs can update it at the same time?
why do some people write if(0 == x) instead of if(x == 0)?
Difference between Function to pointer and pointer to function
Why c is procedure oriented?
What is pointer & why it is used?
Explain what are linked list?
An organised method of depicting the use of an area of computer memory used to signify the uses for different parts of the memory a) swap b) extended memory c) memory map d) all of the above
int i[2], j; int *pi;i[0] = 1; i[1] = 5; pi = i; j = *pi + 1 + *(pi + 1)Value of j after execution of the above statements will be a) 7 b) 6 c) 4 d) pointer
Tell me what are bitwise shift operators?
What is a header file?
What are the application of void data type in c?
Which is better between malloc and calloc?
What is difference between far and near pointers?