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

Java

Abc

Uploaded by

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

Java

Abc

Uploaded by

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

7636

C20-CM-WD– 502
*
7636
BOARD DIPLOMA EXAMINATION (Inst.), (C-20)
JULY—2023
DCME – FIFTH SEMESTER EXAMINATION
JAVA PROGRAMING
Time : 3 hours ] [ Total Marks : 80

PART—A 3×10=30

Instructions : (1) Answer all questions.


(2) Each question carries three marks.
(3) Answers should be brief and straight to the point and shall
not exceed five simple sentences.

1. Define a class and give its syntax.

2. Write any three differences between method and constructor.

3. What is inheritance? List the types of inheritance.

4. What is method overriding?

5. List any three file access operations in Java.

6. List any three constructors for the LinkedList class.

7. List different states in life cycle of a thread.

8. Write any three most common types of exceptions that might occur in
Java.

What is an Applet?

Describe any three sources of events.


9.
*
10.

*
/7636 1 [ Contd...
PART—B 8×5=40

*
(1) Answer
Instructions : all questions.
(2) Each question carries eight marks.
(3) Answers should be comprehensive and criterion for
valuation is the content but not the length of the answer.

11. (a) List and explain primitive data types of Java. 2+6

(OR)

(b) Explain different types of constructors with example program. 4+4

12. (a) What is an interface? Describe the concept of creating and


implementing interfaces with an example program. 2+6

(OR)

(b) How to design a package? Discuss the various levels of access


protection available for packages. 4+4

13. (a) Write a program to read and write lines of text through console
input and output streams. 8

(OR)

(b) Explain the ArrayList class by writing a program that uses add()
and remove() methods. 8

14. (a) Describe the concept of synchronization with an example program. 3+5
(OR)

(b) Write a program to make use of try and catch blocks to handle an
arithmetic exception. 8

(a) Discuss the steps involved in designing and executing an Applet. 8


15.
(OR)
* (b) List and explain any four event listener interfaces. 2+6

*
/7636 2 [ Contd...
PART—C 10×1=10
*
Instructions : (1) Answer the following question.
(2) The question carries ten marks.
(3) Answer should be comprehensive and the criterion for
valuation is the content but not the length of the answer.

16. Design a class to represent a bank account. Include the following


members :
Fields :
• Name of the Account Holder
• Account Number
• Balance Amount in the Account
Methods :
• To assign initial values
• To deposit an amount
• To display Name and balance
Write necessary Java code for the above data.

*
/7636 3 AA23(013)-PDF

You might also like