please give code for this 1 2 4 7 11 16
Answer Posted / kiran
#include<stdio.h>
#include<conio.h>
void main()
{
int p=1;
for(int i=1;i<=5;i++)
{
printf("%d ",p);
p+=i;
}
getch();
}
| Is This Answer Correct ? | 35 Yes | 23 No |
Post New Answer View All Answers
What is volatile variable in c?
write a c program thal will find all sequences of length N that produce the sum is Zero, print all possible solutions?
How can I do peek and poke in c?
program to find error in linklist.(i.e find whether any node point wrongly to previous nodes instead of next node)
The % symbol has a special use in a printf statement. How would you place this character as part of the output on the screen?
What is string function in c?
Explain how can I make sure that my program is the only one accessing a file?
Here is a neat trick for checking whether two strings are equal
Is it better to use malloc() or calloc()?
What is a void * in c?
What's the right way to use errno?
What is the use of function overloading in C?
Why can't I perform arithmetic on a void* pointer?
what is the differnce between programing langauge and tool? is sas is a programing langauge r tool?
Is printf a keyword?