JAVA EXAM – QUESTION PAPER
SECTION – A (15 × 1 = 15 Marks)
Definitions, True/False, Fill in the Blanks
1. Define Polymorphism.
2. True or False: JVM converts Java program into bytecode.
3. Fill in the blanks: In Java, the keyword _______ is used to inherit a class.
4. Define Exception.
5. What is the full form of JUnit?
6. True/False: An Applet must contain a main() method.
7. Fill in the blanks: The method used to start a thread is _______.
8. Define Wrapper Class.
9. True/False: Interfaces in Java support multiple inheritance.
10. Fill in the blanks: The block that always executes in exception handling is _______.
11. Define Encapsulation.
12. True/False: PMD is used for static code analysis.
13. Fill in the blanks: The life cycle method used to draw graphics in an applet is _______.
14. Define Command■line Argument.
15. True/False: In multithreading, sleep() method stops thread permanently.
SECTION – B (5 × 5 = 25 Marks)
Write detailed answers with examples
Q1. Explain Method Overloading and Method Overriding in Java. Give proper examples for each.
Q2. Explain the types of inheritance supported in Java. Draw diagrams and provide example programs.
Q3. What is Exception Handling? Explain its keywords (try, catch, finally, throw, throws) with examples.
Q4. Explain the Delegation Event Model in AWT. Describe Event Source, Event Object, and Event
Listener with examples.
Q5. Explain the life cycle of an Applet. Describe each stage with a neat diagram.
SECTION – C (5 × 10 = 50 Marks)
Very Long Questions — 2 to 3 pages each
Q1. Explain Object-Oriented Programming (OOP) concepts in Java. Describe Abstraction,
Encapsulation, Inheritance, and Polymorphism with diagrams and real-life examples.
Q2. Explain Multithreading in Java in detail. Discuss thread life cycle, thread creation methods, thread
priorities, synchronization, and write suitable programs.
Q3. What is Unit Testing? Explain JUnit framework, annotations, assertions, test cases, and code
coverage in detail. Provide a complete example.
Q4. Explain Debugging in Java. Describe debugging tools, breakpoints, watches, stepping, call stack,
and the role of PMD in static code analysis with diagrams.
Q5. Explain Event Handling in Java with detailed theory. Include flowcharts, diagrams, and complete
example programs using ActionListener, MouseListener, and WindowListener.