garyfitz
3/20/2018 - 10:31 AM

.push

.push Javascript Example

//Push the odd numbers from 9 through 1 to myArray using a for loop.
var myArray = [];

// Only change code below this line.
for (var i = 9; i > 0; i-=2){
  myArray.push(i);
}