Jawaharlal Nehru Technological University Hyderabad
Jawaharlal Nehru Technological University Hyderabad B.Tech II OBJECT ORIENTED PROGRAMMING THROUGH JAVA Previous Question Paper (November/December - 2017 - R16)
Note: This question paper contains two parts A and B. Part A is compulsory which carries 25 marks. Answer all questions in Part A. Part B consists of 5 Units. Answer any one full question from each unit.
PART - A
Differentiate between print() and println() methods in Java.
Answer
The print() method displays the argument passed to it and keeps the cursor on the same line. The println() method displays the argument and moves the cursor to the beginning of the next line.
What are symbolic constants? Explain with examples.
Answer
Symbolic constants are identifiers that represent a fixed value that cannot be changed during program execution. In Java, they are typically declared using the final keyword combined with static to ensure they are class-level constants.
Using these improves code readability and maintainability by replacing magic numbers with meaningful names.
What are the methods available in the character streams?
Answer
Sign in to view the complete answer paper.
What is the significance of the CLASSPATH environment variable in creating/using a package?
Answer
Sign in to view the complete answer paper.
What is the difference between error and an exception?
Answer
Sign in to view the complete answer paper.
What is synchronization and why is it important?
Answer
Sign in to view the complete answer paper.
What is the significance of Legacy class? Give example.
Answer
Sign in to view the complete answer paper.
What is the purpose of String Tokenizer class? Explain.
Answer
Sign in to view the complete answer paper.
What are the differences between JToggle button and Radio button?
Answer
Sign in to view the complete answer paper.
What is an adapter class? Explain with an example.
Answer
Sign in to view the complete answer paper.
PART - B
What is meant by byte code? Briefly explain how Java is platform independent.
Answer
Sign in to view the complete answer paper.
Explain the significance of public, protected and private access specifiers in inheritance.
Answer
Sign in to view the complete answer paper.
Explain different parts of a Java program with an appropriate example.
Answer
Sign in to view the complete answer paper.
How does polymorphism promote extensibility? Explain with example.
Answer
Sign in to view the complete answer paper.
Explain the process of defining and creating a package with suitable examples.
Answer
Sign in to view the complete answer paper.
Give an example where interface can be used to support multiple inheritance.
Answer
Sign in to view the complete answer paper.
What is the accessibility of a public method or field inside a nonpublic class or interface? Explain.
Answer
Sign in to view the complete answer paper.
Describe the process of importing and accessing a package with suitable examples.
Answer
Sign in to view the complete answer paper.
Differentiate between Checked and UnChecked Exceptions with examples.
Answer
Sign in to view the complete answer paper.
Write a program to create four threads using Runnable interface.
Answer
Sign in to view the complete answer paper.
What are the different ways to handle exceptions? Explain.
Answer
Sign in to view the complete answer paper.
How many ways are possible in java to create multiple threaded programs? Discuss the differences between them.
Answer
Sign in to view the complete answer paper.
Differentiate between ArrayList and a Vector? Why ArrayList is faster than Vector? Explain.
Answer
Sign in to view the complete answer paper.
How an Hashtable can change the iterator? Explain.
Answer
Sign in to view the complete answer paper.
Explain the Bit Set and Calendar classes in detail.
Answer
Sign in to view the complete answer paper.
Discuss the differences between HashList and HashMap, Set and List.
Answer
Sign in to view the complete answer paper.
List and explain different types of Layout managers with suitable examples.
Answer
Sign in to view the complete answer paper.
How to move/drag a component placed in Swing Container? Explain.
Answer
Sign in to view the complete answer paper.
Discuss about different applet display methods in brief.
Answer
Sign in to view the complete answer paper.
What are the various components of Swing? Explain.
Answer
Sign in to view the complete answer paper.