0% found this document useful (0 votes)
1 views4 pages

Important Questions For Java

The document outlines important questions for Java, organized into five units covering topics such as constructors, object-oriented concepts, inheritance, exception handling, and AWT controls. Each unit contains long and short answer questions designed to assess understanding of Java programming principles and practices. The document serves as a study guide for Java learners to prepare for examinations or assessments.

Uploaded by

naveenroyals71
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
1 views4 pages

Important Questions For Java

The document outlines important questions for Java, organized into five units covering topics such as constructors, object-oriented concepts, inheritance, exception handling, and AWT controls. Each unit contains long and short answer questions designed to assess understanding of Java programming principles and practices. The document serves as a study guide for Java learners to prepare for examinations or assessments.

Uploaded by

naveenroyals71
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Important questions for java

Unit-1:
Long answer Questions.
1. Explain the constructor & types of constructors in java with example programs?
2. Describe object-oriented concepts in Java with examples?
3. Define method overloading in java with example programs?
4. Explain the arrays & types of arrays with example program?
5. Explain the usage of static keyword with an example program?
6. Difference b/w object-oriented programming & procedure-oriented programming
language?
7. Explain about string class with an example program?
8. Explain how command line arguments work in Java with an example program?
9. Explain the looping & Decision-making statements with an example program?
Short answer questions.
1. Explain the concept of Bytecode and why Java is platform-independent.
2. List any three features of Java.
3. What is method overloading?
4. Define the use of this keyword.
5. What are command line arguments?
6. List any six features of Java
7. What is the purpose of the static keyword in Java?
8. How do you declare and initialize a one-dimensional array?
Unit-2:
Long answer questions:
1. Explain why Java doesn't support multiple inheritance through classes. Write a
program to achieve Multiple Inheritance using Interfaces?
2. Explain inheritance in java and its types with an example?
3. Explain the usage of super keyword with an example program?
4. Define method overriding in java with example programs?
5. Give sample application to design packages with sample program?
6. Define packages & types of packages with an example program?
7. Define interfaces & write a program to implement interfaces?
8. Explain the mechanism of importing packages with example program?
9. Describe the concept of Access modifiers in java with an example?
Short answer questions:
1. Explain the use of the super keyword.
2. Differentiate between Method Overloading and Method Overriding.
3. Define a Package. How do you import a package into your program?
4. What is an Interface? Why is it used?
5. What is inheritance? Why it is used?
6. Define abstract class with an example.
7. What is method overriding?
8. Explain why Java doesn't support multiple inheritance in java?
Unit-3:
Long answer questions:
1. Explain the concept of I/O streams & types of streams with neat sketch?
2. Explain briefly about hierarchy of collection frame work?
3. Explain the collection interfaces with an example program?
4. Explain the collection classes with an example program?
5. How to access a collection via iterator with example program?
6. Explain the various file access operations using file streams?
Short answer questions:
1. Differentiate between Byte Stream and Character Stream classes.?
2. List any three methods of the File class?
3. What is the purpose of the Array List class in the Collection framework?
4. Explain the use of an Iterator in collections & Define Iterator in Java.?
5. What is the purpose of [Link] and [Link]?
6. What is the Collection Framework?
7. Name any two Collection interfaces?
8. What is the difference between List and Set?
Unit-4:
Long answer questions:
1. Explain briefly about exception handling & types of exception handling with
examples?
2. Explain exception handling in Java with try-catch-finally blocks with example
program?
3. Explain the various states of a thread life cycle with a neat diagram?
4. Explain briefly about multithreading & its types with examples?
5. Explain briefly thread life cycle with neat sketch?
6. Explain about synchronization with example program?
7. Write a program to implement thread priority MIN_PRIORITY, NORM_PRIORITY,
MAX_PRIORITY in java?

8. Explain about creating the thread by using runnable interfaces & extending thread
class with example program?

9. Explain inter-thread communication and deadlocks?

Short answer questions:


1. What is an exception? List any four built-in exceptions in Java?
2. Define thread life cycle.
3. What is synchronization?
4. What is inter-thread communication?
5. What is a deadlock?
6. Explain the use of the finally block?
7. Why do we need the synchronized keyword?
8. What is a thread, and how does it differ from a process?

Unit-5:
Long answer questions:
1. Explain the lifecycle of an applet (init, start, paint, stop, destroy) with a diagram?
2. Describe AWT controls and their usage with examples?
3. Demonstrate handling mouse events with sample program?
4. Demonstrate handling keyboard events with sample program?
5. Demonstrate the event handling mechanism / Explain event delegation model in Java?
6. Explain about applets & implementation of sample applet program?
7. Explain the concept of working with colors & font class with example program?
8. Explain about graphics class methods with an example program?
9. Explain about AWT classes & its types with examples?
Short answer question:
10. Define AWT.
11. What are listener interfaces?
12. What is the use of TextField in AWT?
13. What are mouse events?
14. Differentiate between an Applet and an Application?
15. List the attributes of the <APPLET> tag in HTML?
16. What is the Delegation Event Model?
17. List any four methods of the Graphics class?
18. What is the life cycle of an applet?
19. List out the sources of events in java?

…………………………………… THE END…………………………………........

You might also like