Loading

c program to find factorial of number

C Program to Find Factorial of Number


#include<stdio.h>
#include<conio.h>
#include<math.h>
void main()
{
    int a,i,j,k;
    clrscr();
    printf("\n\t\t***PROGRAMME TO CALCULATE FACTORIAL OF A NO.***");
    printf("\n\t\tENTER A NO.: ",a);
    scanf("%d",&a);
    j=1;
    for(i=a;i>0;i--)
    {
     j=j*(i);

     }
    printf("\n\t\tTHE FACTORIAL OF NO IS: %d",j);
    getch();
   }

This entry was posted in , . Bookmark the permalink.

Leave a reply