//Find Factorial
//Downloaded from www.c4cprog.co.nr
#include<conio.h>
long int s=1;
void fact(int a)
{
s=s*a;
a--;
if(a>0)
fact(a);
else
printf("The Factorial of the given No. is : %ld",s);
}
void main()
{
int a;
clrscr();
printf("\nEnter The No : ");
scanf("%d",&a);
fact(a);
getch();
}
Programs Can Also Be Downloaded From The Folders Below....[Or Scroll Down]
Factorial using recursive Function
Click Here To Download C File Of This Program
Subscribe to:
Post Comments (Atom)
0 comments:
Post a Comment