0% found this document useful (0 votes)
4 views

java questionbank

The document consists of two question sets focused on Java programming, including short and long questions covering topics such as object-oriented programming, data types, exceptions, and AWT components. Each set includes specific inquiries about Java concepts, programming examples, and comparisons between different Java features. Additionally, there are sections for short notes summarizing key Java topics.

Uploaded by

akhilsingh070307
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
4 views

java questionbank

The document consists of two question sets focused on Java programming, including short and long questions covering topics such as object-oriented programming, data types, exceptions, and AWT components. Each set includes specific inquiries about Java concepts, programming examples, and comparisons between different Java features. Additionally, there are sections for short notes summarizing key Java topics.

Uploaded by

akhilsingh070307
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

QUESTION SET - I

Part-A : Short Questions

a. What is object-oriented programming?


b. What are the different types of variables in Java?
c. What are control structures in Java?
d. What is the difference between a while loop and a do-while loop in Java?
e. What are the different types of exceptions in Java?
f. What is the difference between a private and a protected method in Java?
g. What is the purpose of the Collections class in Java?
h. What is a thread in Java?
i. What is the purpose of the InputStream class in Java?
j. What is the purpose of the Frame class in AWT?

Part-B : Long Questions

a) i) Explain the types of Lopping Statements.

ii) Give an example of each one.


Q.2 OR
b) i) What is Inheritance? Illustrate the types of inheritances.

ii) Write a java program to implement multilevel inheritance concept.


a) i) What is a Java Exception and its Types

ii) Explain about try, catch, statements with examples


Q.3 OR
b) i) Give the difference between checked and unchecked exceptions.

ii) Show the use of finally statements with examples.


a) i) What is an Operator? Explain type of operators in Java
ii) Give example programs of each.
Q.4 OR
b) i) Define Daemon Threads? Explain with an example.

ii) Explain about Thread Life Cycle in details.


a) i) Define String? Explain different String declarations with an example.
Q.5 ii) Write a java program to perform the arithmetic operations.
OR
b) i) Write a Java program to find the factorial by taking input from the user.

ii) Explain any five string methods.


a) i) Explain the concept of Input/Output in Java and Give an example.

ii) What is an abstract class? Given an example


Q.6 OR
b) i) List out any 10 AWT classes and their syntax.

ii) Difference between AWT and Swings?

Part-C : Short Notes

a. Arrays in java
b. Inheritance in java
c. Packages vs Interface
d. Try-Catch-Finally
e. Switch Keyword
f. AWT in Java

"Wishing you best of luck!"


QUESTION SET - II

Part-A : Short Questions

a. What is the basic structure of a Java program?


b. What are the features of Java?
c. What are the different types of variables in Java?
d. What are the four principles of OOP?
e. What is the difference between a while loop and a do-while loop in Java?
f. What are the different types of exceptions in Java?
g. What is the difference between an abstract class and an interface in Java?
h. What is the difference between ArrayList and Vector?
i. What is the FileOutputStream class in Java?
j. What is the difference between Window and Frame in AWT?

Part-B : Long Questions

a) i) Define Data Type. Criticize the declaration of variable in Java.

ii) Explain Java exception hierarchy.


Q.2 OR
b) i) What is an Array? Explain types of arrays in Java with example.

ii) Write a Java program to read and display the array elements.
a) i) What is a Java Exception and its Types.

ii) Explain about try, catch, statements with examples.


Q.3 OR
b) i) Demonstrate Nested try statements with an example.

ii) What is mean by OOP? Explain OOP Concepts?


a) i) Compare and contrast ArrayList and Vector in terms of performance.

ii) Describe the Map interface in Java. How does it different from Set and List.
Q.4 OR
b) i) Define Daemon Threads? Explain with an example.

ii) Contract in detail about throw and throws statements.


a) i) Write the difference between String and StringBuffer classes.

ii) Create a java program to display “Hello! Java” using Class, Object and Method.
Q.5
OR
b) i) Write a Java program to sum of two numbers by taking input from the user.
ii) What is an interface? List the rules to create an interface in java with example

a) i) Wha a) i) What are the common exceptions encountered during file I/O operations in Java

ii) Write a java program to implement single inheritance concept.


Q.6 OR
b) i) b) i) Explain about the AWT Menu design.

ii) Define Class, Method, and Object? Show the syntax to define these in java.

Part-C : Short Notes

a. Decision Making
b. Checked and Unchecked
c. Break Keyword
d. JDK, JRE and JVM
e. String in java
f. AWT Components

"Wishing you best of luck!"

You might also like