MCA (Revised) Term-End F, Xamination June, 2OO7

Download as pdf or txt
Download as pdf or txt
You are on page 1of 4

MCA (Revised)

Term-End F,xamination
June, 2OO7
MCS-ff.l : OBJECTORIENTED
TECHNOLOGIES
AND JAVA
PROGRAMMING
Time : 3 hours
Nofe r

l.

Maximum Marks : 700

Question number 1 is compulsory. Attempt any


three questionsfrom the rest.

(a)

What is java virtual machine ? Explain.

(b)

What is the differencebetween rnethod overloading


and method overriding ? Explain with the help of
3+3
examples.

(c)

What is data abstraction? Why are classesknown as


3+2
abstract data types ?

(d)

When is private specifier used in a java program ?


Explain with suitableexample.

What is the difference between an applet and java


application program ?

(e)

MCS-024

P.T.O.

(f)

what happens if we apply final keyword to


(i)

a class

(ii)

a function

(iii) a variable
(g)

Write the output of the following :


(i) x:-10,y:1
X
X

(ii) String51 : "Hello,,;


String52 : "Hello";
String53 : "HELLO";
(S1 + t'equalstt+ 52 + rf )f l
System.out.println
+ 51 equals(Sz)h
(S1 + "equals" + 53 + f f >ft
System.out.println
+ 51 . equals(S3));
(iii) inti-150;
byte b : byte (i.21;

Write a program in java to print all the argumentsin


reverseorder given at comrnandline.

What are the differences in abstract classes and


interfacesin java ? Explain.

(b)

what is finalize() method in java ? Explain.

(c)

What is a package ? How do you create a package


in java ? Explain with example.

(h)

2.

(a)

MCS-024

(d)

can you have two variableswith the same name in


two interfaces which you are using to derive a new
interface ?
e.g.

inti X

Yinti

\ /
Z
Explain your answer.

3' (a)
ilfT:'[;T'ffi;:

?Exp'Iain
]:ililothrows
6

(b) What arethe rnethodsof creatingthreadsin java ?

4-

Explain.

(c)

What is the use of super keyword in java ? Explain.

(d)

why do we need static data in a class?

(a)

Write an Applet in java to print the directoryin which


an HTML file containingthat applet is stored.

Explain the three differentmethods used to create an


object of InetAddressclass.

(c)

What are the various colour constructors?

(d)

Write a program in java to copy one file to another


file using command line arguments.

'|
(b)

MCS-024

P.T.O.

5.

Write a program in java to accept an integer number


from the user. An exception is thrown if number
enteredis

(b)

What are the JAR and Manifestfiles in java ?

(c)

Static functions can only accessstatic data. Explain.

(d)

Differentiate between TCP client and TCP server


socket with the help of an example.

(a)

MCS-024

11 , 0 0 0

You might also like