Write A Program In C To Calculate The Factorial of Inputted Number By A User.(Programmed By Sandesh Acharya)

Program for Calcualting the Factorial of Inputted Number ByUsers..

#include<stdio.h>
main() {
int num, i;
long fact=1;
printf(Enter a number which factorial is to be calculated:");
scanf("%d", &num);
for(i=1; i<=num; i++)
fact*=i;
printf(The factorial is: %d",fact);
return 0;
}

Comments

Popular posts from this blog

Our Mobile Apps... Sandesh Acharya Programs>>> ByProgrammer: Sandesh Acharya

Creating A Simple Virus In Python. Creator:Sandesh Acharya