fork download
  1. #include <stdio.h>
  2.  
  3. int main(void) {
  4. int a=1, b, c=1;
  5.  
  6. scanf("%d\n",&b);
  7. while(c<=b){
  8. a=a*c;
  9. c=c+1;
  10. }
  11. printf("%d\n",a);
  12. // your code goes here
  13. return 0;
  14. }
  15.  
Success #stdin #stdout 0s 5320KB
stdin
4
stdout
24