Skip to main content

Modern Programming Languages MCQs with Answers

Practice important Modern Programming Languages MCQs with answers and explanations.

Multiple Choice Questions

Q761: What does the continue statement do in JavaScript loops?
  • A: Exits the loop
  • B: Skips the rest of the current iteration
  • C: Repeats the current iteration
  • D: Stops all script execution
View Answer
B

Q762: In JavaScript, the result of var x = "2" + "2"; is:
  • A: 4
  • B: "22"
  • C: Error
  • D: Null
View Answer
B

Q763: JavaScript arrays are susceptible to:
  • A: Aliasing
  • B: Overloading
  • C: Overriding
  • D: Error-prone initialization
View Answer
A

Q764: Which attribute is recommended by W3C for specifying JavaScript type?
  • A: language
  • B: type
  • C: script
  • D: src
View Answer
B

Q765: What does the === operator compare in JavaScript?
  • A: Values only
  • B: Types only
  • C: Values and types
  • D: Arrays
View Answer
C

Q766: What will the following statement output? document.write("JavaScript" + "is" + "great!");
  • A: JavaScriptisgreat!
  • B: JavaScript is great!
  • C: JavaScript_is_great!
  • D: JavaScript-is-great!
View Answer
B

Q767: What does an object in JavaScript represent?
  • A: A collection of strings
  • B: A collection of data types and functions
  • C: A single number
  • D: Only functions
View Answer
B

Q768: In JavaScript, which object model provides access to browser characteristics?
  • A: Document Object Model (DOM)
  • B: Browser Object Model (BOM)
  • C: Global Object Model (GOM)
  • D: Window Object Model (WOM)
View Answer
B

Q769: The method to access properties of an object in JavaScript is:
  • A: using curly brackets
  • B: using dot notation
  • C: using square brackets
  • D: using colons
View Answer
B

Q770: The Document Object Model (DOM) in JavaScript is used to:
  • A: Access browser history
  • B: Access HTML content
  • C: Access operating system
  • D: Access browser settings
View Answer
B

Test Your Knowledge

Take a timed quiz on Modern Programming Languages

🚀 Start Quiz Now