CPP Program For Factorial Post author:admin Post published:August 8, 2018 Post category:CPP Programms Post comments:0 Comments #include<iostream.h> #include<conio.h> void main() { clrscr(); long a,b,c=1; cout << "enter any number" << endl; cin >>a; for(int i=1;i<=a;i++) { c=c*i; } cout << c << endl; getch(); } Output: enter any number 5 factorial=120 Tags: CPP program for factorial, factorial number in cpp, factorial number program You Might Also Like Calculate your age in CPP August 5, 2018 Matrix Addition In CPP August 7, 2018 Function Overloading in CPP August 5, 2018 Leave a Reply Cancel replyCommentEnter your name or username to comment Enter your email address to comment Enter your website URL (optional) Save my name, email, and website in this browser for the next time I comment.