fork download
  1. #include <stdio.h>
  2.  
  3. int main(void) {
  4. int i,a[11];
  5. a[0]=0;
  6. a[1]=1;
  7. printf("%d\n",a[1]);
  8. for(i=2;i<11;i++){
  9. a[i]=a[i-1]+a[i-2];
  10. printf("%d\n",a[i]);
  11. }
  12. return 0;
  13. }
Success #stdin #stdout 0s 5312KB
stdin
Standard input is empty
stdout
1
1
2
3
5
8
13
21
34
55