fork download
  1. #include <stdio.h>
  2.  
  3. int a(int n){
  4. if(n==0){
  5. return 0;
  6. }else{
  7. return 3*a(n-1)+4;
  8. }
  9. }
  10. int main(void) {
  11. // your code goes here
  12. int k;
  13. k=a(2);
  14. printf("%d",k);
  15. return 0;
  16. }
  17.  
Success #stdin #stdout 0s 5308KB
stdin
Standard input is empty
stdout
16