Question: A function will stop executing when it reaches a _____ statement. Question 1 options: Save Question 2 (1 point) To return an element with the

A function will stop executing when it reaches a _____ statement.

Question 1 options:

Save

Question 2 (1 point)

A function will stop executing when it reaches a _____ statement. Question

To return an element with the id demo from the document (this will return the element, not the contents or state) - write the code as you would in the html document - just the one line. var element = ____________;

Question 2 options:

Save

Question 3 (1 point)

1 options: Save Question 2 (1 point) To return an element with

What is the time complexity of the following function? function fun(n) { if (n

Question 3 options:

1)

O(1)

2)

O(n)

3)

O(n^2)

4)

O(n logn)

Save

Question 4 (1 point)

the id demo from the document (this will return the element, not

What is the output of the following code? var fruits = ["Banana", "Orange"]; fruits.splice(1, 1, "Lemon", "Kiwi"); document.getElementById("demo").innerHTML = fruits;

Question 4 options:

Save

Question 5 (1 point)

the contents or state) - write the code as you would in

What will be the output of the following code? var abc = ["A", "B"]; var num = ["1", "2", "3"]; var newA = abc.concat(num); document.getElementById("demo").innerHTML = abc;

Question 5 options:

Save

Question 6 (1 point)

the html document - just the one line. var element = ____________;

What will be the output of the following code? var fruits = ["Banana", "Orange", "Apple"]; fruits.shift(); document.getElementById("demo").innerHTML = fruits;

Question 6 options:

Save

Question 7 (1 point)

Question 2 options: Save Question 3 (1 point) What is the time

The push method adds an element to the end of an array.

Question 7 options:

1) True
2) False

Save

Question 8 (1 point)

complexity of the following function? function fun(n) { if (n Question 3

What will be the output of the following code? var a = ["3", "2", "1"]; document.getElementById("demo").innerHTML = a.sort();

Question 8 options:

Save

Question 9 (1 point)

options: 1) O(1) 2) O(n) 3) O(n^2) 4) O(n logn) Save Question

What will be the output of the following code? var a = ["1", "2"]; document.getElementById("demo").innerHTML = a;

Question 9 options:

Save

Question 10 (1 point)

4 (1 point) What is the output of the following code? var

What will be the output of the following code? var fruits = ["Banana", "Orange", "Apple", "Mango"]; document.getElementById("demo1").innerHTML = fruits.pop();

Question 10 options:

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 Databases Questions!