DekGenius.com
Home
(current)
Dictionary
BOOKS
LYRICS
CHORD
SCRIPT & CODE EXAMPLE
Karaoke language
Search
Go
SCRIPT & CODE EXAMPLE
CODE EXAMPLE FOR CPP
calculate factorial
int factorial(int n) { int res = 1, i; for (i = 2; i <= n; i++) res *= i; return res; }
PREVIOUS
NEXT
Tagged:
#calculate
#factorial
ADD COMMENT
Topic
COMMENT
Name
1+2 =
Submit