P17281 [GeeksforGeeks] Small factorial0854
普及-
题目描述

Calculate factorial of a given number N.

Example 1:
Input: 5
Output: 120
Explanation: 1 * 2 * 3 * 4 * 5 = 120.

Your Task:
You don't need to read or print anything. Your task is to complete the function find_fact() which takes n as input parameter and returns factorial of N.

Expected Time Complexity: O(N)
Expected Space Complexity: O(1)

Constraints:
1 <= N <= 18

输入格式

见题面

输出格式

见题面

样例输入
5
样例输出
120