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

MCS-024__merged

Uploaded by

mrritekkumar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
47 views

MCS-024__merged

Uploaded by

mrritekkumar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 42

No.

of Printed Pages : 4 MCS-024


MASTER OF COMPUTER

APPLICATIONS/ BACHELOR OF

COMPUTER APPLICATIONS

[MCA (REVISED)/BCA (REVISED)]

Term-End Examination

December, 2023
MCS–024 : OBJECT ORIENTED TECHNOLOGIES
AND JAVA PROGRAMMING

Time : 3 Hours Maximum Marks : 100


Weightage : 75%
Note : Question No. 1 is compulsory. Attempt any

three questions from the rest.

1. (a) What is a class ? How does it accomplish

data hiding ? Explain with an example. 5

(b) Differentiate between AWT and Swing

components. Give suitable example for

each. 5
P. T. O.
[2] MCS-024

(c) Explain the relationship between

inheritance and polymorphism. Give

example of each. 5

(d) What is Java Bean ? Briefly discuss the


features of Java Bean. 5

(e) Explain why main( ) method is not


included in writing a Java applet program
using an applet coding. 5

(f) Compare structured programming and


object oriented programming. 5

(g) Discuss the utility of final and finalize


keywords in Java. Give example code for
each. 5

(h) How does datagram socket differ from


stream socket ? 5

2. (a) Write a Java applet to display. “Java is an


object oriented programming language” in
red color. Support your code with suitable
comments. 5
[3] MCS-024

(b) What is a layout manager ? Explain the


flow layout and border layout. Also explain
how a layout is set. 8

(c) What are packages in Java ? How do we


create a package in Java ? What are the
steps to add Classes and Interfaces in a
package ? 7

3. (a) Differentiate between thread and process.


Explain Java thread model using thread
life cycle. 7

(b) Compare Applet and Servlet. Write the


steps to incorporate applet in a webpage. 8

(c) Explain method overriding in Java using a


program in Java. 5

4. (a) Write a Java program for writing files in


“C:\javafiles\” location. Support your
program with suitable comments. 7

(b) Write the steps of JDBC in establishing a


connection for creating dynamic website for
INSERT/UPDATE the attendance record
for students of a college. 7

P. T. O.
[4] MCS-024

(c) What is synchronization ? Explain how


methods are synchronized in Java with the
help of an example. 6

5. Write short notes on the following : 4×5=20

(a) Object serialization

(b) Liberals and its types

(c) Servlet life cycle

(d) Garbage collection

(e) Role of cookies in session handling

MCS–024
No. of Printed Pages : 4 MCS-024

MASTER OF COMPUER
APPLICATIONS (MCA) (REVISED)/
BACHELOR OF COMPUTER
APPLICATIONS B.C.A. (REVISED)
Term-End Examination
June, 2023
MCS-024 : OBJECT ORIENTED TECHNOLOGIES
AND JAVA PROGRAMMING

Time : 3 Hours Maximum Marks : 100


Weightage : 75%
Note : Question No. 1 is compulsory. Attempt any
three questions from the rest.

1. (a) Explain the basic features of object

oriented programming language. 5

(b) Why is Java called machine independent

language ? Explain the functionality of

JVM. 5

P. T. O.
[2] MCS-024

(c) Differentiate between constructor and


method, give example for both. 5

(d) What is an abstract class ? Explain the use


of abstract class with an example. 5

(e) What are cookies and session variables ?


Briefly discuss the utility of both. 5

(f) Explain the different steps in the life cycle


of an applet. 5

(g) Discuss the relationship between data


abstraction and encapsulation. 5

(h) Explain the usage of container in Java


Applet and Servlet. 5

2. (a) Explain how exception handling is


performed in Java. Briefly discuss the
concept of checked exception and
unchecked exception, with an example of
each. 10

(b) Briefly discuss the concept of listener in


Java. Write a program in java to
implement mouse motion listener, support
your program with suitable comments. 10
[3] MCS-024

3. (a) What is string class ? How is it different

from String Buffer class ? Write a java

program to find the length of a given

string. 7

(b) What is servlet ? Explain how session

handling is performed in servlet

programming. 7

(c) What is an Interface ? Write a java

program to show how a class implements

two interfaces. 6

4. (a) What is RMI in Java ? Write the steps to

create stub and skeleton. 7

(b) Write a java program to create a volume

class. Derive cube and sphere classes from

it. Define constructor for these three

classes. 7

(c) What is Synchronization ? Explain how

methods are synchronized in Java, with

the help of an example. 6

P. T. O.
[4] MCS-024

5. Write short notes on the following : 5×4=20

(a) Dynamic Binding

(b) Stream Tokenizer

(c) JDBC Drivers

(d) Function Overloading

MCS–024 7,070
No. of Printed Pages : 3 MCS-024

MCA (Revised) / BCA (Revised)


Term-End Examination
June, 2022

MCS-024 : OBJECT ORIENTED TECHNOLOGIES AND


JAVA PROGRAMMING

Time : 3 hours Maximum Marks : 100


(Weightage : 75%)

Note : Question no. 1 is compulsory. Answer any


three questions from the rest.

1. (a) What is an abstract class ? How is it used to


implement polymorphism in Java ? Give
suitable example in support of your answer. 5

(b) What is an applet ? Why is main( ) not


included in writing a Java applet program ? 5

(c) Explain the process of inter-thread


communication in Java, with the help of a
suitable example. 5

(d) Differentiate between throw with throws


statement. Give example code for each. 5

MCS-024 1 P.T.O.
(e) What is classpath ? Explain the utility of
classpath, with the help of a suitable
example. 5
(f) Compare private and protected access
specifiers. Give suitable example for each. 5
(g) Differentiate between Method-overloading
and Method-overriding, with the help of a
suitable example. 5
(h) What is layout manager ? Explain any two
layouts in Java. 5

2. (a) What are proxy servers ? Explain the usage


of anonymous proxy servers in designing
mailing applications. 6
(b) How does Servlet differ from Applet ?
Discuss all the phases of a servlet lifecycle. 7
(c) Write a program in Java to copy the text
content of one file into another file. Support
your program with suitable comments. 7

3. (a) What is StringBuffer class ? Write a


program in Java to append a given string to
a StringBuffer object. 6
(b) Write a program to pass parameters to an
Applet using a web page. Also write the
phases of an Applet lifecycle. 6
(c) What is an event in Java ? How does Java
handle events ? Write a program in Java to
capture any event generated by keyboard. 8

MCS-024 2
4. (a) Write a Java program to create a Teacher
class and derive PGT, TGT and PRT classes
from Teacher class. Define appropriate
construction for all the classes. Also define
a method to display information of Teacher.
Make necessary assumptions as required. 10

(b) Write a Java program to set up JDBC and


execute an SQL statement on a database
table ‘BOOK’, with fields BOOK_ISBN,
BOOK_AUTH, BOOK_PRICE,
BOOK_PUBL. The SQL statement should
find the BOOK_AUTH and BOOK_PRICE
of the BOOK having ISBN = 500123. 10

5. (a) What is an Exception ? Briefly explain the


causes of Exceptions. Describe how multiple
exceptions are caught in Java, with the help
of a suitable program code. 10
(b) Write a Java program to print Fibonacci
series, up to the nth term entered by the
user. Support your program with suitable
comments. 5
(c) Explain the Java RMI architecture, with
the help of a diagram. 5

MCS-024 3 P.T.O.
No. of Printed Pages : 4 MCS-024

M. C. A. (REVISED)/B.C.A. (REVISED)
Term-End Examination
December, 2022
MCS-024 : OBJECT ORIENTED TECHNOLOGIES
AND JAVA PROGRAMMING

Time : 3 Hours Maximum Marks : 100


Weightage : 75%

Note : Question No. 1 is compulsory. Attempt any


three questions from the rest of the
questions.

1. (a) What is method overloading ? Explain with


suitable example. 5

(b) Explain the relationship between


inheritance and polymorphism through an
example. 5

(c) Distinguish between ‘Final’, ‘Finally’ and


‘Finalize’ keywords. Give example for each.
6

P. T. O.
[2] MCS-024

(d) Explain container class, and discuss its


significance in Java GUI programming. 4

(e) Explain each component of the statement


‘public static void main (string args[ ])’. 5

(f) What is Java applet ? How is it different


from Java application program ? 5

(g) Explain the Java RMI architecture with


the help of a diagram. 5

(h) What is Java Bean ? Give advantages of


java beans in programming. 5

2. (a) Explain the usage of Grid Layout and Grid


Bag Layout in a Java Applet. 5

(b) How String Class differs from String


Buffer Class ? Explain with suitable
example. 5

(c) What is an applet ? Discuss all the phases

of applet life cycle. 5

(d) Explain GET and POST methods of servlet

programming, with the help of suitable

code. 5
[3] MCS-024

3. (a) Write a java program to create a file


named ‘ignou-txt’ and write ‘Hello IGNOU’
in it. 6

(b) Write a java program for ‘writing output on


console’ using PrintWriter( ) method. Give
suitable comments for readability of your
program. 6

(c) What is exception in Java ? What are the


basic causes of occurrence of an exception ?
Write a program in Java, to show the
concept of exception handling. Support
your program with suitable comments. 8

4. (a) What is inheritance ? How is inheritance


related to interface ? Explain, how multiple
inheritance can be implemented using
interface in Java. Give suitable example.
10

(b) Explain the steps of JDBC in establishing


a connection for creating a dynamic
website for INSERT/UPDATE the
attendance record for employees of an
organization. 10
P. T. O.
[4] MCS-024

5. (a) Write a Java program which takes two


3 × 3 matrices as input and find sum of the
two matrices ? Define constructor for
initializing the matrix object. Give suitable
comments for readability of your code. 10

(b) Write a Java program to print factorial of a


number entered by user. 5

(c) Compare object oriented programming and


structured programming. Give advantages
of object oriented progamming over the
structured programming. 5

MCS–024
No. of Printed Pages : 3 MCS-024

MCA (Revised) / BCA (Revised)


Term-End Examination
December, 2021

MCS-024 : OBJECT ORIENTED TECHNOLOGIES AND


JAVA PROGRAMMING

Time : 3 hours Maximum Marks : 100


(Weightage : 75%)

Note : Question no. 1 is compulsory. Answer any three


questions from the rest.

1. (a) Compare data abstraction and data hiding.


Give an example of each. 5

(b) Compare Inheritance and Polymorphism.


Give an example of each. 5

(c) Why is Java called machine independent


and architecture neutral ? What is the role
of JVM (Java Virtual Machine) ? 5

(d) Write a JAVA program to find the factorial


of a given number. Define appropriate class
and methods. 5

MCS-024 1 P.T.O.
(e) What is an exception ? Write any three
actions that can be taken after an
exception occurs in a program. 5
(f) What are threads ? Explain how threads
are created by implementing Runnable
Interface. 5
(g) What is serialization ? Differentiate
between Transient and Volatile keyword. 5
(h) Discuss the architecture of Applet, with the
help of a suitable block diagram. 5

2. (a) Briefly discuss the methods used by Applet


during their life cycle. 5
(b) What are proxy servers ? When should you
use anonymous proxy servers ? 5
(c) What is RMI ? Which protocol does it use ?
Discuss the security problem in RMI. 5
(d) What is session tracking ? Discuss the role
of cookies in session tracking. 5

3. (a) What is Java Bean ? Briefly discuss the


features of Java Beans. How does Java
Bean differ from an instance of a normal
Java class ? 6
(b) Explain method overloading and method
overriding. Give suitable example for each. 8
(c) What is Synchronization ? Why is it
important ? Explain the use of
synchronized method in multithreading. 6

MCS-024 2
4. (a) What is the difference between & operator
and the && operator ? Give suitable
example for each. 5

(b) What is a constructor ? Explain the use of


constructor with the help of a program. 5

(c) What is finalize( ) method ? Write the


properties of finalize( ) method. Write the
declaration statement for finalize( )
method. 5

(d) Compare checked exceptions with


unchecked exceptions. Give an example for
each. 5

5. Write short notes on the following : 45=20

(a) Methods Used for Interthread Communication

(b) Object Serialization and its Working

(c) Package in Java

(d) AWT and Swing

MCS-024 3 P.T.O.
No. of Printed Pages : 3 MCS-024

MCA (Revised) / BCA (Revised)


Term-End Examination
June, 2021

MCS-024 : OBJECT ORIENTED TECHNOLOGIES


AND JAVA PROGRAMMING

Time : 3 hours Maximum Marks : 100


(Weightage 75%)

Note : Question no. 1 is compulsory. Attempt any three


questions from the rest.

1. (a) Compare Object Oriented and Procedure


Oriented approaches. Give salient features
of both. 5

(b) What is Dynamic Binding ? Explain the


advantage of dynamic binding. 5

(c) Explain Function Overloading with the


help of suitable example. 5

(d) Explain why the main method in Java is


always static. 5

MCS-024 1 P.T.O.
(e) What is an Interface ? Write a program to
show how a class implements two interfaces. 5
(f) What is Object Serialization ? Briefly
discuss the working of Object Serialization. 5

(g) Compare StringBuffer Object with String


Object. When should StringBuffer Object be
preferred over String Object ? 5

(h) What is Stream Tokenizer ? Discuss with


suitable example. 5

2. (a) Discuss the life cycle of applet, with the


help of a suitable block diagram. 5

(b) What is a Stream Socket ? How is it


different from Datagram Socket ? 5

(c) Briefly discuss the different kinds of drivers


used in JDBC. 5

(d) How do Servlets differ from Applets ?


Briefly discuss the Servlet Life Cycle. 5

3. (a) What is RMI ? Briefly discuss the RMI


object hierarchy. Discuss how distributed
applications are created using RMI. 10
(b) Write a JAVA program that overloads the
function ‘SUM’ that computes the sum of
two integers and the sum of two float
valves. 5
(c) Compare doGet() and doPost() method. 5
MCS-024 2
4. (a) What is a Literal ? How many types of
literals are there in Java ? 5

(b) Briefly discuss the term Garbage Collection.


Give advantages and disadvantages of
Garbage Collection. 5

(c) What are uses of final keyword in Java ? 5

(d) Explain how threads are created by


implementing Runnable Interface. What is
thread priority ? 5

5. Write short notes on the following : 45=20

(a) Transient and Volatile Modifiers

(b) Random Access File and its Methods

(c) TCP/IP Sockets

(d) Multidimensional Array in JAVA

MCS-024 3 P.T.O.
No. of Printed Pages : 4 MCS-024

M. C. A. (REVISED)/B.C.A. (REVISED)

Term-End Examination
December, 2020

MCS-024 : OBJECT ORIENTED TECHNOLOGIES


AND JAVA PROGRAMMING

Time : 3 Hours Maximum Marks : 100

Weightage : 75%

Note : Question No. 1 is compulsory. Attempt any


three questions from the rest of the
questions.

1. (a) What is Multithreading ? How is


multithreading supported in Java ? 5

(b) What is explicit casting ? Explain with


suitable example. 5

(c) What is the difference between declaring a


variable and defining a variable ? Explain
with the help of an example. 5

Lot-II P. T. O.
[2] MCS-024

(d) Explain the following and their usage


using suitable examples : 5

(i) Extends

(ii) Implements

(e) Write a java program to convert a given


string to uppercase and also display the
length of the string. 5

(f) What is datagram socket ? Explain the use


of datagram socket with the help of a
program in java. 5

(g) Write a java program to draw a triangle. 5

(h) What is function overloading ? Explain it


with the help of a program, written in
java. 5

2. (a) How does java application differ from java


applet ? Do we write “public static void
main(string args [ ]) in applet ? Justify. 5

(b) Write a java program to copy the text


content of one file into another file.
Support your program with suitable
comments. 7
[3] MCS-024

(c) What is the relation between interface and

inheritance ? Explain how multiple

inheritance can be implemented in Java

using interface. 8

3. (a) Explain the life cycle of servlet, along with

a program that creates a simple servlet

generating HTML to write “welcome

students”. 10

(b) What is an exception ? What is runtime

exception ? Write a java program to search

element in a given array with provision of

exception handling. 10

4. (a) How java implements the model of

interprocess synchronization using threads ?

Explain with the help of a program. 10

(b) What is Inheritance ? What are the

advantages of inheritance ? Write a java

program to demonstrate implementation of

inheritance. 10

P. T. O.
[4] MCS-024

5. Write short notes on the following : 5 × 4 = 20

(a) Cookies and their role in session handling

(b) Layout manager and its role

(c) Buffered stream classes and their utility

(d) Uses of super keyword

(e) Garbage collection

MCS–024 7,750
No. of Printed Pages : 4 I MCS-024
MCA (Revised) / BCA (Revised)
Term-End Examination

MCS-024 : OBJECT ORIENTED TECHNOLOGIES


AND JAVA PROGRAMMING

Time : 3 Hours) [Maximum Marks : 100


(Weightage 75%)

Note: Question number 1 is compulsory. Answer any


threqusionfmthequsion.

1. (a) What do you understand by "method


overloading"? How it is different from "method
overriding"? Give suitable example for each.
5
(b) What is the purpose of setting class path?
How it supports the execution of Java
program? Write the steps, performed to set
the class path. 5
(c) What do you mean by "garbage collection"
in Java? Give advantages and disadvantages
of garbage collection. 5

MCS-024 / 3060
(d) What is interface in Java? Write a java
program to exhibit, how to define and
implement interface. 5

(e) What are the uses of "this" keyword in java?


Explain with the help of an example. 5

(f) What is byte code? Explain the difference


between compiled code of Java and compiled
code of C. 5

(g) Write a program in Java to convert the string


"IGNOU" in lower case i.e. "ignou". Give
suitable comments in your code, to increase
the readability. 5

(h) What is an abstract class? How it is used to


impliment polymorphism in Java? 5

2. (a) Explain the life cycle of applet, with suitable


diagram. 5

(b) Write a program in Java that reads text from


the key board and writes it to a ".txt" file.
Incorporate suitable comments in your
program, to improve the readability of your
logic. 7

(2) MCS-024 / 3060


(c) Explain "«", "" and "&" bitwise operators
in Java. Write a Java program to perform "cc"
bitwise operator on a given number. 8
3. (a) What is certainer (in context of java)? Explain
the significance of container in Java GUI
program. 5
(b) What is stream tokenizer in Java? What is
its significance ? Discuss the instance
variables defined in streamtokenizer? Give
an example to show the use of
streamtokenizer. 7
(c) Write a client & server programs in Java to
show the TCP connection establishment and
data transfer. 8
4. (a) Write a JAVA program to draw a color filled
line and a color filled rectangle. 5
(b) Explain the term RMI in Java. Briefly discuss
the steps involved in creation of stub and
skeleton. 7
(c) Discuss the concept of multithreading in
Java. What are the advantages of
multithreading? Explain the interthread
communication with the help of an example.
8
MCS-024 / 3060 (3)
5. (a) What do you understand by "exception", in
context of Java? How it is handled, explain
with the help of suitable example code in
Java? 5

(b) What is a layout manager? Briefly discuss


the role of layout manager in Java. Explain
the flow layout and grid layout with the help
of an example for each. 7

(c) Differentiate between any two of the


following: 8

(i) String class and stringBuffer class

(ii) Throw statement and throws statement

(iii) Final and Finally

-X-

(4) MCS-024 / 3060


9364
No. of Printed Pages.: 4 1MCS-0241

MCA (Revised) / BCA (Revised)

Term End Examination, 2019


-

MCS-024 : OBJECT ORIENTED TECHNOLOGIES


AND JAVA PROGRAMMING

Time : 3 Hours] [Maximum Marks : 100


(Weightage 75%)

Note : Question no. 1 is compulsory and carries 40 marks.


Attempt any three questions from the rest.

1. (a) How String Buffer differs from String ? Write a


program in Java, which takes your name as input
and print it in upper case.
[5]

(b) How does Java handle events ? Write a program


in Java to capture an event generated by
keyboard.
[5]

(c) What are the uses of "this" keyword in Java ?


Explain with the help of an example. What is an
applet ?
[5]

MCS-024/9500
Write a program to generate a circle in an
(d)
[5]
applet ?

What do you understand by session tracking in


(e)
Java ? Discuss any technique, used for session
[5]
tracking.

Differentiate between superclass and


(f)
subclass. Write a program in Java to show the

concept of reusability. [51

What is exception in Java ? How exception


(g)
handling is performed, demonstrate with an

example ? [51

(h) Explain constructor overloading with suitable

example. [5]

What is checked exception in java ? How it is


2. (a)
different from unchecked exception ? Explain

briefly. [5]

(b) Write a Java program to find whether a given


element is present in a integer array of size ten

of not. - [51

(2)
(c) What is a layout manager ? Discuss the Flow
layout and grid layout, give suitable example for
each. [1 0]

(a) Briefly explain the role of following classes in Java


Network programming : [5]

(I) Socket

(ii) Datagram Packet

(b) What is the difference between a process and a


thread ? Mention any three methods of thread
class and describe them briefly. [8]

(c) What is an event ? What are components of an


event? Differentiate between semantic event and
low-level event. [7]

(a) Write a Java program to create shape class.


Overload method area ( ) to calculate area of
circle and rectangle. Define appropriate
constructors in the program. [6]

(b) What are Input stream and output stream classes


in java ? List and explain any two methods of each
class. [5]
MCS-024/9500 ( 3) [P.T.O.]
(c) Explain how garbage collection takes place in

Java, also list advantages of garbage collection.


[4]

(d) What is an interface ? Write a java program to

show, how a class implements two interface.[5]

5. Write short notes on the following : [20]

Java Beams and its advantages

(ii) Class and object

(iii) Applet Architecture

(iv) Access specifiers

(v) Bitwise operators in java

MCS-024/9500 (4)
0031
No. of Printed Pages : 3 MCS-0241
MCA (Revised) / BCA (Revised)
Term-End Examination, 2019
MCS-024 : OBJECT ORIENTED TECHNOLOGIES
AND JAVA PROGRAMMING
Time : Three Hours] [Maximum Marks : 100
(Weightage 75%

Note : Question No. 1 is Compulsory. Attempt any three


questions from the rest.

1. (a) Write a java program to read the contents of


binary file and write it on the standard output. [10]

(b) What is purpose of Serialization of an object ?


How does the volatile modifier to a data type affect
serialization ? [5]

(c) Justify "Java is secure and architectural neutral


language". [3]

(d) What are cookies and sessidn objects ? Where


do we use them ? [5]

(e) Explain the concept of inheritance and


polymorphism, with an example of each. [7]
MCS-024 (1) [P.T.O.]
(f) Differentiate between AWT and Swing
Components. [5]

(g) What is the difference between notify( ) and notify


All( ) method. [5]

2. (a) What is exception ? What are causes of


exception ? What can be done once an exception
is caught ? Explain use of finally clause in
exceptions handling, with the help of an example.
[10]

(b) Differentiate between following : [10]

(i) Public member and private member

(ii) Overloading and Overriding

(iii) Java application and Applet

(iv) FOR statement and WHILE statement

3. (a) What is Multithreading ? What is the advantage


of multithreading in Java ? [5]

(b) What are Interfaces in Java ? What do you


understand by 'implementing interfaces' ? Explain
with the help of an example. [7]

MCS-024 (2)
(c) What is JDBC ? What are the characteristics of
JDBC ? Write a program to demonstrate how
JDBC connection is established. [8]

(a) What is String in Java ? Explain any three


constructors of String Class. Write a program in
Java to find length of a given string and display
the string in upper case. [10]

(b) What is servlet ? How servlet differs from Applet?


Explain the lifecycle of Applet. [10]

5. (a) Write a Java program to create student class with


data member student_name, roll-number and
Marks. Define appropriate constructor in the
program. Create array of ten student objects. Also
display the name and rollnumber of the student
with highest marks (in the array created). [10]

' (b) What is RMI ? Explain RMI architecture with


suitable diagram. [5]

(c) What are Java Beans ? Discuss the utility of Java


Beans. Explain the features of Java Beans. [5]

MCS-024 (3) 9000


No. of Printed Pages : 3 I mcs-0241
MCA (Revised) / BCA (Revised)
Term-End Examination
December, 2018
OkESSS 3

MCS-024 : OBJECT ORIENTED TECHNOLOGIES AND


JAVA PROGRAMMING

Time : 3 hours Maximum Marks : 100


(Weightage : 75%)

Note : Question no. 1 is compulsory. Attempt any three


questions from the rest.

1. (a) What do you understand by 'this' keyword ?


Explain its usage with an example. 5

(b) What is an event in Java ? Describe


different components of an event.

(c) What is an interface ? Discuss the utility of


-interface with suitable example. 5

(d) What are cookies ? Discuss the role o f


cookies in session tracking. 5

(e) Compare AWT and Swing components. 5

(f) Write a Java program, to find factorial of a


given number. 5
MCS-024 P.T.O.
(g) What is a layout manager ? Explain Border
layout with an example. 5

(h) Explain the Java RMI architecture with


the help of a diagram. 5

2. (a) Write a Java program that reads the


content of a text file and counts the number
of white spaces, number of characters,
number of words and number of full stops
in the content. Support your code with
comments, to describe your logic. 10
(b) What is multithreading ? Explain the steps
for creating thread in Java. Also explain
the predefined thread priorities in Java. 10

3. (a) What are class and objects ? Explain how


an object is created in Java ? Also explain
the role of constructor in Java using Java
code. 10
(b) What is Polymorphism ? Explain the
difference between method overloading and
method overriding with the help of
example. 10

4. (a) Explain the life cycle of Applet. List the


methods involved in it. 10
(b) Write a Java program which takes two
3 x 3 matrices as input and finds the sum of
the two matrices. Define constructor for
initialization of matrix objects. 10
MCS-024 2
5. Write short notes on the following (Give example
for each) : 4x5=20

(a) Message Passing

(b) Java Beans

(c) Strings in Java

(d) Package

MCS-024 3 10,000
No. of Printed Pages : 3 I MCS-024

MCA (Revised) / BCA (Revised)


Term-End Examination
June, 2018
CJ r C.)

MCS-024 : OBJECT ORIENTED TECHNOLOGIES AND


JAVA PROGRAMMING

Time : 3 hours Maximum Marks : 100


(Weightage 75%)

Note : Question no. 1 is compulsory. Attempt any three


questions from the rest of the questions.

1. (a) What is method overloading ? Explain with


suitable example. 5
(b) What is an abstract class ? How is it used
to implement polymorphism in Java ? Give
suitable example in support of your answer. 7
(c) What is JVM ? Explain advantages of JVM. 3
(d) Differentiate between "Final", "Finally" and
"Finalize" statements. 6
(e) Compare throw statement in Java with
throws statement. 4

MCS-024 1 P.T.O.
(f) Explain container class in Java. Give its
significance for Java GUI programming. 5

(g) What is public access specifier ? How is it


different from private access specifier ?
Explain with example. 5

(h) What is an applet ? Explain various ways


to execute an applet. 5

2. (a) What is servlet life cycle ? Explain


GET and POST methods in servlet
programming. 10

(b) What is import ? Explain the need of


importing a package in Java. 5

(c) What is a classpath ? Discuss the utility of


classpath with suitable example.

3. (a) What is inheritance ? How is inheritance


related to interface ? Explain, how multiple
inheritance can be implemented using
interface in Java. Give suitable example. 10
(b) Write a Java program to create a Teacher
class and derive Professor/
Associate_Professor/Assistant_Professor
class from Teacher class. Define
appropriate constructor for all the classes.
Also define a method to display information
of Teacher. Make necessary assumptions as
required. 10

MCS-024 2
4. (a) What are the features of Object Oriented
Programming ? Explain encapsulation and
its advantages, with an example.
(b) How is String class different from
StringBuffer class ? Write a program in
Java to find the length of a given string. 7

(c) Write a program in Java, to copy the text


content of one file into another file. 7

5. (a) Explain each component of the statement


"public static void main (string args ] )". 6

(b) What is an event in Java ? How does Java


handle events ? Write a program in Java, to
capture any event generated by a keyboard. 7
(c) What is exception in Java ? What are the
basic causes of occurrence of exception ?
Write a program in Java, to exhibit the
concept of exception handling. Support your
program with suitable comments. 7

MCS-024 3 12,000

You might also like