//In the Name of ALLAH //This program takes a number and calculates its factorial. #include #include void main() { int n; int i; int x=1; // *** The Main Body *** // clrscr(); printf("Enter a number please. The program gives back its factorial.\n"); scanf("%d",&n); for(i=n; i>0; i--) { x=i*x; } printf("%d! = %d",n,x); getch(); }