fork download
  1. #include <iostream>
  2. using namespace std;
  3. int factorial(int num) {
  4. int kq;
  5. for (int i=1; i<= num;i++)
  6. num = num*i;
  7. }
  8. int main() {
  9. // your code goes here
  10. factorial(4);
  11. return 0;
  12. }
Success #stdin #stdout 0s 5288KB
stdin
Standard input is empty
stdout
Standard output is empty