How To Exam?

a knowledge trading engine...


Veer Narmad South Gujarat University 2011-5th Sem B.C.A Computer Application SB-1501 java pragramming language - 501 Third Year ( ) - Question Paper

Friday, 26 April 2013 06:10Web



SB-1501

Third Year B. C. A. (Sem. V) Examination March / April - 2011 501, Java Programming Language

Time : Hours]    [Total Marks : 70

Instructions :

(1)

Seat No.:


M    CnsLLnlcj.L{l [qoicu    u? snqw <h>h41.

Fillup strictly the details of signs on your answer book.

Name of the Examination :

T. Y. B.C.A. (Sem. 5)

Name of the Subject:

501, Java Programming Language

Student's Signature


-Subject Code No.:

1

5

0

1

-Section No. (1,2,.....): Nil

(2) Numbers to the right side of every questions indicate Marks.

Answer following : (any seven)

14


(a)    What is benefit of making Thread as synchronized ?

(b)    What is difference between notifyO and notify A110 ?

(c)    Assume that class A extends class B, which extends class C. Also all the three classes implement the method testO- Is it possible that a method in a class A invoke the testO method defined in class C (without creating a new instance of class C). If yes, then how ?

(d)    What is the output when the following program is compiled and run ?

public class test {

public static void main (string args[ ] ) { int i;

float f = 2.3f; double d = 2.7;

i = ((int) Math.ceil (f)) * ((int) Math.round (d)); System.out.printIn(i);

}

}

(e)    What is the result of compiling and running the following program :

public class test {

public static void main (string args [ ]) {

string strl = abc :

string strl =def;

string str3 = strl.concat (str2);

strl.concat (str2); system.out.println (strl);

}

}

(f)    Which method defined in Integer class can be used to convert an Integer object to primitive int type.

(g)    Which of the following is correct ? Select the one correct answer :

(i)    An import statement, if defined, must always be the first non-comment statement of the file.

(ii)    Private members are accessible to all classes in the same package.

(iii)    An abstract class can be declared as final.

(iv)    Local variables cannot be declared as static.

(h)    Which of these statements are true. Select the two correct answers.

(i)    For each try block there must be atleast one catch block difined.

(ii)    A try block may be followed by any number of finally blocks.

(iii)    A try block must be followed by atleast one finally or catch block.

(iv)    If both catch and finally blocks are defined, catch block must precede the finally block.

2    (a) Explain the concept of Threads. Discuss the creation

and execution of threads.

OR

(a)    How java handle unused objects ? Discuss the process of memory management by cleaning the unused objects in Java in detail.

(b)    Discuss java class structure with respect to C++. Explain the limitations of java class structures.

OR

(b)    What is package ? How java restricts the access of classes and methods at package level using access modifiers ?

(c)    Explain the concept of Interface. What is difference between Java class and Interface ?

3    (a) Explain Class variables. Class methods and Instance

variables, instance methods providing appropriate examples. Also discuss inheritance in java.

OR

(a)    Explain java architecture. How java programs execute ?

(b)    Write the process of handling exceptions in Java. Describe how exceptions are handled at code level ?

OR

(b)    Define package. How do we design a package and a class or an interface to a package ?

(c)    What is difference between over loading and over riding ?

4    (a) Explain the concept of Applet. How it is different

from Application ?

OR

(a)    Explain the class hierarchy of APPLET class.    7 Discuss how to pass parameters of APPLET ?

(b)    What is garbage collection ? Explain the process of 5 garbage collection in java.

OR

(b)    How java class structure differ from C++ ?    5

(c)    Describe any three built-in functions of string and    3 stringBuffer class.

(a)    Answer following : (any two)    8

(i)    String and StringBuffer class.

(ii)    Thread life cycle

(iii)    Garbage Collection

(b)    Write code which accept name using command line argument and display it in reverse order.    3

SB-1501]    4    [ 400 ]







Attachment:

( 0 Votes )

Add comment


Security code
Refresh

Earning:   Approval pending.
You are here: PAPER Veer Narmad South Gujarat University 2011-5th Sem B.C.A Computer Application SB-1501 java pragramming language - 501 Third Year ( ) - Question Paper