fork download
  1. #include <stdio.h>
  2. //a{n} = -6a{n-1} -9a{n-2}, a{1}=1, a{2}=2(再帰あり版)
  3. int rec(int n){
  4.  
  5. }
  6.  
  7. int main(void) {
  8. int n = 4;
  9. printf("数列a%dの値は%d\n", n, rec(n));
  10. return 0;
  11. }
  12.  
  13.  
Success #stdin #stdout 0s 5320KB
stdin
Standard input is empty
stdout
数列a4の値は0