#include<stdio.h>
#include<stdlib.h>
long factorielleR(long n, long acc)
{
printf("(%ld, %ld)\n", n, acc);
if (n == 0)
return acc;
return factorielleR(n-1, acc * n);
}
long factorielle(long n)
{
return factorielleR(n, 1);
}
int main()
{
long a = 4;
printf("%ld ! = %ld\n", a, factorielle(a));
getch();
return 0;
}