Math, asked by adianshu1, 1 year ago

1*2*3*4*5*6*7*8*9*10= trick??

Answers

Answered by Adwita
1
3628800 is the correct answer.............................


adianshu1: trick??
Adwita: We have to multiply all the nos.
Adwita: simple
Answered by princedisuz10
0
// Program to print the solution of the series

// f(n)= (1) + (2*3) + (4*5*6) ... n using recursion

#include <stdio.h>

 

// Recursive function for finding sum of series

// calculated - number of terms till which sum of terms has

//              been calculated

// current    - number of terms for which sum has to be

//              calculated

// N          - Number of terms in the function to be calculated

int seriesSum(int calculated, int current, int N)

{

    int i, cur = 1;

 

    // checking termination condition

    if (current == N + 1)

        return 0;

  

    // product of terms till current

    for (i = calculated; i < calculated + current; i++)

        cur *= i;

 

    // recursive call for adding terms next in the series

    return cur + seriesSum(i, current + 1, N);

}

  

int main()

{

    // input number of terms in the series

    int N = 5; 

 

    // invoking the function to calculate the sum

    printf("%d\n",


Anonymous: programmer spotted lol
Adwita: I cant understand it......
adianshu1: couldn't understand...
Similar questions