#include<stdio.h> #include<conio.h> void main() { int n,i; double f=1; clrscr(); printf("\n Enter n\n"); scanf("%d", &n); for(i=1;i<=n;++i) f=f*i; /* finds the factorial */ printf("\n factorial of %3d=%.01f",n,f); getch(); }Output 1:Enter n factorial of 4=24Output 2:Enter n factorial of 6=720