C program for finding factorial by recursion

Here is a C program to find a factorial by recursive method –

int factorial (int x ) {
          return ( n==0? 1: n*(fact(n-1)));
}

Add a Comment

Your email address will not be published. Required fields are marked *