Coding challenge-1
# Coding Challenge-1
(Please Enable Desktop mode on Mobiles.)
Required Knowledge-Factorial's
Factorial of a number is simply the following Product,
To calculate factorial of n(denoted by n!)
n! = n x (n-1) x (n-2) x ................3 x 2 x 1.
Example -
4! = 4 x (4-1) x (4-2) x (4-3).
=> 4! = 4 x 3 x 2 x 1.
=> 4! = 24.
Similarly,
5! = 5 x (5-1) x (5-2) x (5-3) x (5-4)
=> 5! = 5 x 4 x 3 x 2 x 1.
=> 5! = 120.
Challenge--
Develop a Factorial Calculator-
input - The Number(N) of which you want the factorial.
output - N!
Example--
input - 7
output - 5040
(Please Enable Desktop mode on Mobiles.)
Required Knowledge-Factorial's
Factorial of a number is simply the following Product,
To calculate factorial of n(denoted by n!)
n! = n x (n-1) x (n-2) x ................3 x 2 x 1.
Example -
4! = 4 x (4-1) x (4-2) x (4-3).
=> 4! = 4 x 3 x 2 x 1.
=> 4! = 24.
Similarly,
5! = 5 x (5-1) x (5-2) x (5-3) x (5-4)
=> 5! = 5 x 4 x 3 x 2 x 1.
=> 5! = 120.
Challenge--
Develop a Factorial Calculator-
input - The Number(N) of which you want the factorial.
output - N!
Example--
input - 7
output - 5040
All The Best
1 Comments
If You are using a mobile please use desktop mode
ReplyDelete