Java
Java
1. Basic Concepts:
- **Options:**
1. Bytecode
2. Multithreading
3. Object-oriented programming
4. Garbage collection
- **Answer:** Bytecode
2. Object-Oriented Programming:
- **Options:**
1. Abstraction
2. Encapsulation
3. Compilation
4. Inheritance
- **Answer:** Compilation
3. Exception Handling:
- **Options:**
1. throw
2. throws
3. try
4. catch
- **Answer:** throw
4. Collections Framework:
- **Q4.** Which of the following interfaces does not extend the Collection interface in Java?
- **Options:**
1. List
2. Set
3. Map
4. Queue
- **Answer:** Map
5. Multithreading:
- **Options:**
1. startThread()
2. run()
3. start()
4. begin()
- **Answer:** start()
- **Options:**
2. Executing bytecode
3. Managing memory
7. Access Modifiers:
- **Q7.** Which access modifier allows a class to be accessible only within its own package?
- **Options:**
1. public
2. protected
3. private
4. default
- **Answer:** default
- **Q8.** What is the primary difference between an interface and an abstract class in Java?
- **Options:**
- **Answer:** Abstract classes can have instance variables, while interfaces cannot.
9. Strings:
- **Options:**
1. join()
2. append()
3. concat()
4. merge()
- **Answer:** concat()
- **Options:**
1. To free up memory by removing unused objects