Question: Write loops that perform the following tasks. Output all data to the console. Use a for loop to print out all the EVEN numbers from

Write loops that perform the following tasks. Output all data to the console.
Use a for loop to print out all the EVEN numbers from zero (0) to 100.
Use a for loop to print out the SUM of all the ODD numbers between 1 and a user provided value.
Create an array of the following values... 1,1,2,3,5,8,13,21.
Use a for loop to print the values of the array in order.
Use a for of loop to print the values of the array in order.
Use a for loop to print the values of the array in reverse order.
Use a for loop to calculate the SUM of the values in the array.
Use a for of loop to calculate the SUM of the values in the array.
Use a while loop to remove all the values from the array using the array pop method. Print each removed item to the console.
Ask the user to enter a value larger than 10 and create a while loop that forces them to re-enter the value if the number they entered is not larger than 10.
Write all this code in one JavaScript file.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!