• JavaScript Video Tutorials

Javascript Online Quiz



Following quiz provides Multiple Choice Questions (MCQs) related to Javascript Framework. You will have to read all the given answers and click over the correct answer. If you are not sure about the answer then you can check the answer using Show Answer button. You can use Next Quiz button to check new set of questions in the quiz.

Questions and Answers

Answer : D

Explanation

All of the above options are correct.

Answer : D

Explanation

window.location='http://www.newlocation.com'; is the correct option.

Q 3 - Which built-in method removes the last element from an array and returns that element?

A - last()

B - get()

C - pop()

D - None of the above.

Answer : C

Explanation

pop() method removes the last element from an array and returns that element.

Q 4 - Which of the following function of Number object formats a number with a specific number of digits to the right of the decimal?

A - toExponential()

B - toFixed()

C - toPrecision()

D - toLocaleString()

Answer : B

Explanation

toFixed() − Formats a number with a specific number of digits to the right of the decimal.

Q 5 - Which of the following function of Number object returns a string value version of the current number?

A - toString()

B - toFixed()

C - toLocaleString()

D - toPrecision()

Answer : A

Explanation

toString() − Returns a string value version of the current number.

Q 6 - Which of the following function of String object is used to match a regular expression against a string?

A - concat()

B - match()

C - search()

D - replace()

Answer : B

Explanation

match() − Used to match a regular expression against a string.

Q 7 - Which of the following function of String object returns the primitive value of the specified object.

A - toLocaleUpperCase()

B - toUpperCase()

C - toString()

D - valueOf()

Answer : D

Explanation

valueOf() − Returns the primitive value of the specified object.

Q 8 - Which of the following function of String object causes a string to be displayed as struck-out text, as if it were in a <strike> tag?

A - sup()

B - small()

C - strike()

D - sub()

Answer : C

Explanation

strike() − Causes a string to be displayed as struck-out text, as if it were in a <strike> tag.

Q 9 - Which of the following function of Array object returns true if every element in this array satisfies the provided testing function?

A - concat()

B - every()

C - push()

D - some()

Answer : B

Explanation

every() − Returns true if every element in this array satisfies the provided testing function.

Q 10 - Which of the following function of Array object reverses the order of the elements of an array?

A - reverse()

B - push()

C - reduce()

D - reduceRight()

Answer : A

Explanation

reverse() − Reverses the order of the elements of an array.

javascript_questions_answers.htm
Advertisements