Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

1 - Create an Array named trees with the following values: Sugar Maple, Red Maple, Red Oak, American Beech, Flowering Dogwood, Eastern Redbud 2 -

1-Create an Array named trees with the following values: Sugar Maple, Red Maple, Red Oak, American Beech, Flowering Dogwood, Eastern Redbud
2- Output the Array values using a for loop
document.writeln('For Loop Output:');
3- pop() the last value and then output the Array using document.writeln(trees);
4- push() the value 'Magnolia' onto the Array and output it using document.writeln(trees);
5- Output the length of the array using the length property
6- Sort the array and then output the all of the values
7- Create an array called numbers with the following values: 4,8,2,9,10,12,3,5
8- Use a loop to calculate average. Output the average using document.writeln()
9- Use a loop to calculate sum. Output the final sum using document.writeln()
10- Sort the array and output the values in numbers

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Flash XML Applications Use AS2 And AS3 To Create Photo Galleries Menus And Databases

Authors: Joachim Schnier

1st Edition

0240809173, 978-0240809175

More Books

Students also viewed these Databases questions

Question

Why do corporations utilize different forms of equity?

Answered: 1 week ago

Question

What is the most important part of any HCM Project Map and why?

Answered: 1 week ago