Professional Documents
Culture Documents
Dce 515
Dce 515
Dce 515
:___________________
RK UNIVERSITY
D.ENGG./SEM-IV/REGULAR/MAY-2017
Instructions:
1. Attempt all questions.
2. Make suitable assumptions wherever necessary.
3. Figures to the right indicate full marks.
4. Programmable calculator is not permissible.
SECTION – I
Q.1 (a) Give the appropriate answer from the following questions: 10
1. Which operator is used to concatenate two or more string?
(a) + = = (b) + (c) || (d) ^^
2._______________is collection of classes and interfaces.
(a) package (b) java (c) memory (d) object
3. Which of the following is not primitive data type?
(a) bytes (b) boolean (c) double (d) string
4. What is the environment variable that contains a list of
directories where java looks for classes referenced in a
program?
(a) CLASSPATH (b) PATHFLOW
(c) PATHCLASS (d) PATHSEARCH
5. Which of the following access specifies is usually used with
inheritance.
(a) public (b) private
(c) protected (d) package
6. ____________is selective statement in Java.
(a) continue (b) if (c) for (d) break
7._______________is a reference to current object on which the
method was invoked. (fill the blanks)
8.Constructor with no parameter is called a__________
constructor. (fill the blanks)
9. The first element in an array is accessed using zero as an
index. (True/False)
10. Output of the Java compiler is known as dalvik opcode.
(True/False)
Page 1 of 3
(b) List out all features of Java and explain general structure of 06
Java program.
SECTION – II
Q.4 (a) State whether the following statements are true or false. 10
1. Compile time exceptions can be handled using throws
keyword.
2. To put controls in the form of rows and columns,
GridLayout can be used.
3. MouseListener is an interface for ActionEvent.
4. Applet contains main() method in its life cycle.
5. In Exception, finally block is compulsory.
6. In panel, we can’t set layout.
7. To draw rectangle, drawOval() can be used.
8. To call paint() method of Graphics class, repaint() is
used.
9. To create new applet window, we can use Frame class
in java.
10. We can’t generate more than one exceptions in single
program.
Page 2 of 3
(b) Differentiate checked and unchecked exception. Write a 06
program to generate ArithmeticException.
Q.5 (a) Why do we need layouts in java? List all types of layouts and 06
explain any two with an example.
(b) Differentiate Error and Exception. Write a program to 05
generate and handle ArrayIndexOutOfBoundsException.
(c) Differentiate application and applet. 05
OR
Q.5 (a) 1) Explain life cycle of thread. 06
2) Explain life cycle of an applet with an appropriate example.
(b) Write a program which shows any five controls within applet. 05
(c) Explain the concept of user defined exception with an 05
example.
*************
Page 3 of 3