0
Free MOCK
Apply Internship
Blog
Learning
Roadmap
Others
Login
Beginner
JavaScript
Factorial of a number
Write a function that calculates the factorial of a given number.
Examples
Input:
5
Output:
120
Your Solution
Show Solution
Reset
Output
Run Code
Click 'Run Code' to see the output