Give the Output :
*
* *
* * *
* * * *
Answers were Sorted based on User's Feedback
Answer / sakthipriya
#include<stdio.h>
#include<conio.h>
void main()
{
int n=4, c, k, space, count = 1;
space = n;
for ( c = 1 ; c <= n ; c++)
{
for( k = 1 ; k < space ; k++)
printf(" ");
for ( k = 1 ; k <= c ; k++)
{
printf("*");
if ( c > 1 && count < c)
{
printf(" ");
count++;
}
}
printf("\n");
space--;
count = 1;
}
getch();
}
Is This Answer Correct ? | 0 Yes | 0 No |
Answer / prasanna
int i,j;
for(i=o;i<4;i++)
{
for(j=0;j<=i;j++)
{
printf("*");
}
}
Is This Answer Correct ? | 1 Yes | 6 No |
Name the language in which the compiler of "c" in written?
Which programming language is best for getting job 2020?
write C code to reverse a string such that if i/p is "abc defg hij klmno pqrs tuv wxyz" and the o/p should be "cba gfed jih onmlk srqp vut zyxw"
What is the use of sizeof?
What is a null pointer assignment error? What are bus errors, memory faults, and core dumps?
what is a far pointer
12 Answers ABB, DRDO, ITI, Maruti Suzuki, Steel Plant, TCS, Toyota, Vivo Mobiles,
hi , please send me NIC written test papers to sbabavalli@gmail.com
Differentiate between null and void pointers.
Study the code: void show() main() { show(); } void show (char *s) { printf("%sn",s); } What will happen if it is compiled & run on an ANSI C Compiler? A)It will compile & nothing will be printed when it is executed B)it will compile but not link C)the compiler will generate an error D)the compiler will generate a warning
What is a function simple definition?
What are c identifiers?
helllo sir , what is the main use of the pointer ,array ,and the structure with the example of a programe