what is the code for getting the output as
*
**
***

Answer Posted / gg

#include<stdio.h>
main()
{
int n,i=0,j=0;
printf("Enter an intger : ");//upto n nof *'s
scanf("%d",&n);
while(j<n)
{
for(i=0;i<=j;printf("*"),i++);
printf("\n",j++);
}
}

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is output redirection?

695


Where are local variables stored in c?

571


Can we use visual studio for c?

552


What are the loops in c?

594


What are the disadvantages of c language?

622






given post order,in order construct the corresponding binary tree

2324


Sir,please help me out with the code of this question. Write an interactive C program that will encode or decode multiple lines of text. Store the encoded text within a data file, so that it can be retrieved and decoded at any time. The program should include the following features: (a) Enter text from the keyboard, encode the text and store the encoded text in a data file. (b) Retrieve the encoded text and display it in its encoded form. (c) Retrieve the encoded text, decode it and then display the decoded text. (d) End the computation. Test the program using several lines of text of your choice.

1768


How many loops are there in c?

582


Create a registration form application by taking the details like username, address, phone number, email with password and confirm password (should be same as password).Ensure that the password is of 8 characters with only numbers and alphabets. Take such details for 3 users and display the details. While taking input password must appear as “****”.

2650


What is the heap in c?

646


What is NULL pointer?

677


What extern c means?

546


What is %d used for?

585


Define and explain about ! Operator?

615


How many keywords (reserve words) are in c?

621