Factorial of N
Easy Acceptance 60.00% Points 20.00
Given a positive integer, n. Find the factorial of n.
Examples
Example 1
Example 1
Input: n = 5
Output: 120
Explanation: 1 x 2 x 3 x 4 x 5 = 120
Example 2
Example 2
Input: n = 10
Output: 3628800
Explanation: 10 x 9 x 8 x 7 x 6 x 5 x 4 x 3 x 2 x 1
Companies
Microsoft Visa Arcesium
Track your submissions
Please log in to review your progress and explore code submissions from other participants.
Unlock the full solution
Please log in to access detailed answers and explanations.
Join the discussion
Please log in to join conversations with other participants.