Math, asked by vinayakguptavini9465, 5 months ago

Find sum of series

S= (a 2!) - (a 3!)+ (a 4!)- (a/5!)+

+ (a/10!)

Answers

Answered by Vyomsingh
25

class Series

{

void main(double a)

{

double S=0.0;

for(int b=2;b<=10;b++)

{

int j=1;

for(int k=1;k<=b;k++)

j=j*k;

if(b%2==0)

{

S=S+(a/j);

}

else

S=S-(a/j);

}

System.out.println(S);

}

}

Attachments:
Similar questions