Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <bits/stdc++.h>
- using namespace std;
- #define int long long
- int n;
- int f[25];
- signed main()
- {
- cin >> n;
- f[0] = 1;
- for(int i = 1; i <= n; i++){
- f[i] = f[i - 1] * i;
- }
- cout << f[n] << endl;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement