Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var forLoop = function() {
- for(var i = 10; i >= 0; i -= 2) {
- console.log(i);
- }
- };
- forLoop();
- var whileLoop = function() {
- var whileCondition = 10
- while(whileCondition >= 0) {
- console.log(whileCondition);
- whileCondition -= 2
- }
- };
- whileLoop();
- var doLoop = function() {
- doCondition = false
- do {
- console.log("Apparently I'm never going to have to use this.");
- } while(doCondition === true);
- };
- doLoop();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement