Describe for loop and write a c program to sum the series
X + x2/2! + x3 /3! + …….. up to fifteen terms.
Answer Posted / sai
#include<math.h>
void main()
{
int i,sum=0,x;
clrscr();
printf("enter x value");
scanf("%d",&x);
for(i=1;i<=15;i++)
sum=sum+((x*i)/fact(i));
printf("sum of x+x2/2!.......x15/15!=%d",sum);
getch();
}
| Is This Answer Correct ? | 10 Yes | 13 No |
Post New Answer View All Answers
When a c file is executed there are many files that are automatically opened what are they files?
Why can’t we compare structures?
what do you mean by enumeration constant?
hi any body pls give me company name interview conduct "c" language only
How can I discover how many arguments a function was actually called with?
What is mean by Data Driven framework in QTP? Can any one answer me in details on this regard.
How many levels of pointers can you have?
Why is it usually a bad idea to use gets()? Suggest a workaround.
Why is c called c?
What is a structure member in c?
What is the purpose of void pointer?
What is the size of empty structure in c?
Can a pointer point to null?
Wt are the Buses in C Language
Is c procedural or functional?