fork download
  1. // your code goes here
  2. const fiboarray = [];
  3. fiboarray[0] = 0;
  4. fiboarray[1] = 1;
  5. const size = 15;
  6. for(let i=2; i<size; i++)
  7. {
  8. fiboarray[i] = fiboarray[i-1]+fiboarray[i-2];
  9. }
  10. console.log(fiboarray);
Success #stdin #stdout 0.03s 18872KB
stdin
Standard input is empty
stdout
0,1,1,2,3,5,8,13,21,34,55,89,144,233,377