TopicTestTillArrays
Java Test Paper Variables, Loops, Conditional Statements, Inheritance, Method Overloading, Method Overriding, Encapsulation and Abstraction, and Interfaces in Java 8 Section A: Multiple Choice (1 mark each) 1. Which keyword in Java is used to define a constant? a. static b. final c. const d. var 2. Which loop construct in Java is used when the number of iterations is not known in advance? a. for loop b. while loop c. do-while loop d. if-else loop 3. In Java, what does the super keyword refer to? a. The superclass of the current class. b. The subclass of the current class. c. A reserved keyword with no specific meaning. d. An interface in the current class. 4. What is the primary purpose of method overloading in Java? a. To override methods in a superclass. b. To hide methods in a subclass. c. To create mul...