5. Print Fibbonaci upto 100 in JavaScript

  

        //The Fibonacci sequence is a series where the next term is the sum of pervious two terms.
        //The first two terms of the Fibonacci sequence is 0 followed by 1.
        var t1 = 0, t2 = 1, nextTerm = 0;
        console.log(t1); // print 0 as it is
        console.log(t2); // print 1 as it is
        for (var i = 0; i <= 100; i++) {
        nextTerm = t1 + t2;
        t1 = t2;
        t2 = nextTerm;
        console.log(nextTerm);
        }