fork(1) download
  1. #include <stdlib.h>
  2. #include <stdio.h>
  3. #include <ctype.h>
  4.  
  5. int fuckt(int n){
  6. int i, res;
  7. int *m = (int *)malloc(sizeof(int) * (n + 1));
  8. m[0] = 1;
  9.  
  10. for(i = 1; i <= n; i++)
  11. m[i] = m[i - 1] * i;
  12. res = m[n];
  13. free(m);
  14. return res;
  15. }
  16.  
  17. int main(void) {
  18. int f = fuckt(9);
  19. printf("%d", f);
  20. return 0;
  21. }
Success #stdin #stdout 0s 2244KB
stdin
Standard input is empty
stdout
362880