• Source
    1. #include <stdio.h>
    2.  
    3. int factorial( int n )
    4. {
    5. if( n == 0 )
    6. return 1;
    7. return n * factorial( n-1 );
    8. }
    9.  
    10. int main(void) {
    11. // your code goes here
    12. printf("factorial of 4 : %d ", factorial(4));
    13. return 0;
    14. }
    15.