Mitsom College Course Name: BCA Semester: V Unitwise Assignment Subject: Java Programming (501) Unit I: Introduction To Java

You might also like

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 3

MITSOM COLLEGE

Course Name: BCA Semester: V


Unitwise Assignment
Subject: Java Programming (501)

Unit I : Introduction to Java


Q1.Explain the features of Java.
Q2.Briefly explain about fundamentals of Java object oriented programming.
Q3.How Java is different from C++? Explain.
Q4.Explain the Structure of java program
Q5.What is Byte code?
Q6.Explain about abstract classes and abstract methods.
Q7.List out the properties of static variables and methods.
Q8.Write about Class Path variable.
Q9.Explain various looping and decision making statements in Java with an example.
Q10. Explain the following line used under Java Program
public static void main (String args[ ])
Q11. Explain the following terms: javac, appletviewer, javadoc, jar, jvm and garbage collection,
type casting.
Q12. What is an array? Explain its types with example.
Q13. What is a String in Java? Also explain StringBuffer class with example.
Q14. Why String is immutable or final in Java.
Q15. What is CamelCase notation in Java? Explain with the suitable example.

Unit II : Classes and Objects


Q1. Explain about the classes.
Q2. What is Interface?
Q3. What is Dynamic method dispatch? Explain with an example.
Q4. Explain briefly about access modifiers and their usage.
Q5. What is a method? Provide several signatures of the methods
Q6. Define an abstract class. Explain its purpose. And how is it different from an interface?
Q7. Differentiate between the String and StringBuffer class
Q8.What is a Java package and how is it used? What are the advantages of java package?What
do you understand by package access specifier?
Q9.Which package is always imported by default? Can we import same package/class twice?
Will the JVM load the package twice at runtime?
Q10. How to create and import user defined packages in java program?
Q11. What are Wrapper Classes? Describe the wrapper classes in Java? Why do we need
wrapper classes?
Q12. What is mutable object and immutable object?

Unit III : Collection


Q1.What is Java Collections Framework? List out some benefits of Collections framework?
Q2.What is the benefit of Generics in Collections Framework?
Q3.What are the basic interfaces of Java Collections Framework?
Q4.Differentiate between the following
a. ArrayList and Vector
b. ArrayList and LinkedList
c. Iterator and ListIterator
d. Iterator and Enumeration
e. List and Set
f. HashSet and TreeSet
g. Set and Map
h. HashSet and HashMap
i. HashMap and TreeMap
j. Collection and Collections
k. Comparable and Comparator
Q5.What are the advantages of ArrayList over arrays?
Q6.Why insertion and deletion in ArrayList is slow compared to LinkedList?
Q7.How do we decide when to use ArrayList and When to use LinkedList?
Q8.What is a Map? What are the main Implementations of the Map interface?
Q9.What is a TreeMap? How do you decide when to use HashMap and when to use
TreeMap?
Q10. What is the different Collection Views That Maps Provide?
Q11. How does a Hashtable internally maintain the key-value pairs?

Unit IV : File and Exception Handling


Q1.Explain file input class with suitable example.
Q2.Explain various Stream Classes of Java.
Q3.What is an Exception? How are the exceptions handled in java?
Q4.Explain the exception hierarchy in java.
Q5.What is Runtime Exception or unchecked exception?
Q6.What is checked exception? Differentiate between checked and unchecked exception
Q7.What is difference between
a. ClassNotFoundException and NoClassDefFoundError
b. Error and Exception
c. throw and throws
Q8.What is throw keyword? What is use of throws keyword? What are the possible
combination to write try, catch finally block?
Q9.How to create custom Exception?
Q10.What are FileInputStream and FileOutputStream ? Explain with an example to read and
write into files.
Q11. What are FileReader and FileWriter ? Explain with an example to read and write into
files.
Q12.What are the super most classes of all streams?
Q13.What System.out.println()?
Q14.What is PrintStream and PrintWriter?
Q15.Write a Java program to Read the data of current java file and writing it into another file
Q16.What is the difference between System.out , System.err and System.in?
Unit V : Applet, AWT and Swing Programming
Q1. Write an applet for each of following graphics methods.drawoval() , drawrect() ,
drawline() , filloval()
Q2.What is Applet? How it is differ from Application? Explain.
Q3.Explain applet life cycle.
Q4.What is an Event class? Write a program for mouse event handler.
Q5.Expalin various AWT controls in detail.
Q6.What is difference between importing "java.applet.Applet" and "java.applet.* "?
Q7.Why Swing components are called lightweight component?
Q8.What is Event-Driven-Thread (EDT) in Swing?
Q9.Does Swing is thread-safe? What do you mean by swing is not thread-safe?
Q10.What are differences between Swing and AWT components?
Q11. What is difference between BorderLayout and GridLayout ?
Q12.Is Swing Thread safe in Java?
Q13.How is component different from containers?

***

You might also like