JavaScript Multiple Choice Questions

21. What is defination of an undefined value in JavaScript?

A. Variable used in the code doesn't exist
B. Variable is not assigned to any value
C. Property doesn't exist
D. All of the above

View Answer


22. What are the types of Pop up boxes available in JavaScript?

A. Alert
B. Prompt
C. Confirm
D. All of the above

View Answer


23. what is the disadvantage of using innerHTML in JavaScript?

A. Content can not be replaced everywhere
B. We can use like "appending to innerHTML"
C. Even if you use +=like "innerHTML = innerHTML + 'html'" still the old content is replaced by html
D. The entire innerHTML content is not re-parsed and build into elements, therefore its not slower

View Answer


24. What are the two basic groups of dataypes in JavaScript?

A. Primitive
B. Reference types.
C. All of the above
D. None of the above

View Answer


25. Which of the following are the errors in JavaScript?

A. Load time errors
B. Run time errors:
C. Logical Errors:
D. All of the above

View Answer


26. Which of the following are the functional components in JavaScript?

A. First-class functions
B. Encapsulated-class functions
C. Fixed-class functions
D. All of the above

View Answer


27. Which of the following is not the properties of screen objects in JavaScript?

A. AvailHeight
B. ColorsDepth
C. AvailWidth
D. ColorDepth

View Answer


28. Javascript string using double quotes is exactly the same as a string using single quotes?

A. True
B. False

View Answer


29. Find output of below code
var a = '20';
var b = a = 30;
document.write(a+b);

A. Error in Script
B. '20'30
C. 2030
D. 50

View Answer


30. What is divide by 0 in Javascript? var a = 10;
var b = 0;
document.write(a/b);

A. Nothing is printed
B. 0 is printed
C. Infinity is printed
D. Some Garbage Value

View Answer







Also check :


Discussion


* You must be logged in to add comment.