-
-
Save fredbr/29e936a1dd878f6f6d5aa70450cc6a83 to your computer and use it in GitHub Desktop.
Fatorial Simples
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <bits/stdc++.h> | |
using namespace std; | |
int main() | |
{ | |
int n; | |
cin >> n; | |
int ans = 1; | |
for (int i = 1; i <= n; i++) ans *= i; | |
cout << ans << "\n"; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment