fork(1) download
  1. #include<stdio.h>
  2.  
  3. int counter=0;
  4. int calc (int a, int b) {
  5. int c;
  6. counter++;
  7. if(b==3) return (a*a*a);
  8. else {
  9. c = calc(a, b/3);
  10. return (c+c+c);
  11. }
  12. }
  13.  
  14. int main() {
  15. int k;
  16. k=calc(4, 81);
  17. printf("%d\n", counter);
  18. printf("%d",k);
  19. }
Success #stdin #stdout 0s 5528KB
stdin
Standard input is empty
stdout
4
1728