END TERM EXAMINATION
FOURTH SEMESTER [BCA] APRIL-MAY 2019
Paper Code: BCA-206
Subject: Java Programming
Time: 3 Hours
Maximum Marks: 75
Note: Attempt any five questions including Q.no.1 which is compulsory.
- Q1. Answer any five the following:- (5x5=25)
- (a) How can we pass parameters to an applet?
- (b) What is the use of this and super keyword?
- (c) What is the difference between int and Integer classes?
- (d) What is DriveManager class in JDBC?
- (e) What is a Daemon thread? How can you set priority of a thread?
- (f) Discuss all three usage of Final keyword ?
- (g) difference between adapter and inner classes.
- Q2. (a) What is method overloading? Explain your answer with suitable example. (6.5)
- (b) Explain the concept of default constructor. Does Java provide default constructor? Does Java provide a default copy constructor? Explain your answer with suitable example. (6)
- Q3. (a) What is inheritance? Explain different types of inheritance in Java with suitable diagram and small segment of codes. (6.5)
- (b) What are cookies? Are they good or bad? Justify. (6)
- Q4. (a) Explain the life cycle of a thread. Discuss the process of thread synchronization with the help of appropriate code. (6)
- (b) Explain any 5 String class methods in detail. (6.5)
- Q5. (a) Differentiate between checked and unchecked exceptions. Write a program to demonstrate the concept of user defined exceptions. (7.5)
- (b) Write a program to copy contents of one file to another. (5)
- Q6. (a) What is delegation event model? Write program to explain keyboard event handling. (7.5)
- (b) Differentiate between swing and AWT. (5)
- Q7. (a) Write a program to change background color of applet using three scrollbars representing red, green and blue. (7.5)
- (b) Write short notes on InetAddress class and its factory methods. (5)
- Q8. (a) What is JDBC? Explain all JDBC drivers in detail. (7.5)
- (b) Write a servlet to display current date and time. (5)