RGPV Previous Question Papers BE 3rd Sem Object Oriented Programming Methodology Dec 2006

RGPV Previous Question Papers BE 3rd Semester

Object Oriented Programming Methodology Dec 2006

(Common for CS,EC/IC&IT Engg.)

 

Note.    (i)  Answer all these question .

(ii)  Total six Question are to be attempted

(iii)  There is in internal choice in every question

(iv) Answer of all objective question should be at one place only.

(v)   Answer should be precise and to the point only.

(vi)  Assume suitable missing /misprint data is necessary.

1. Attempt any two objective type question from each unit (a to e) .(Total 10. Nos.of question are to be attempted.)

State whether the following statements are true or false :

(a)  (i) Dynamic binding means that the code associated with a given procedure is not known until the time of the call at run time.

(ii)  Polymorphism is extensively used in implementing inheritance.

(iii)  Object oriented approach cannot be used to create database.

(b)  (i) Object oriented program are executed much faster than conventional programs.

(ii)   In procedure oriented programming ,All data are shared by all functions.

(iii)  Data members can be initialized inside class specified .

©   (i) Class member are public by default.

(ii)  Destructors never take any value.

(iii)  Friend function cannot be used to overload operator.

(d)    (i) inheritance aids data binding

(ii)  A base class is never used to create objects .

(iii)  In multilevel inheritance the construction are executed in the order of inheritance .

(e)             (i) Pure virtual function force the programmer to redefine the virtual function inside the derive

classes.

(ii)  The pointer point to be object that is currently used  to invoke a function .

(iii)  A stream may be connected to more than one file at a time.

2.  (a      How does objects oriented approach differ from objects base approach ?

(b) Distinguish between the following terms.

(i) Object and classes

(ii) Data abstraction and data encapsulation

(iii) Inheritance and polymorphism

(iv) Dynamic binding and message passing

OR

(a)     In what way inheritance is useful in oops?

(b)    What is multiple inheritance and what are its associated problems ? How the concept of

inheritance of specification help to overcome these problems ? Explain

3.  (a) What are objects ? How are they created ?

(b)   Explain with example what is constructor ? How we invoke a constructor function ? Give some of

the special properties of the constructor function .,

OR

(a) Discuss about virtual base class and abstract classes .

(b)  How can be achieve run time polymorphism in C + +?

4.  (a) What is meant by nesting of member function ? Explain with example.

(b) Describe with suitable example the mechanism of accessing data member and member function in

the following cases :

(i) Inside the main program

(ii) Inside a member function of the same class

(iii) Inside a member function of another class

OR

(a)    When do be declare a member of class static ?

(b)    Discuss in brief of the following :

(i) Association

(ii) Recursive association

(iii) Many to many association

(iv) Argument passing

5.  (a) What are the properties of abstract base class ?

(b) What is the difference between interface and abstract base class ?

Implement the following interface :

Interface I { void m (); void n () ;}

OR

(a)   What do you mean by the term ‘Disinheritance’  ?

(b)   Write a class template to represent  a generic vector. Include member function to perform the

following task :

(i) To create the vector

(ii) To modify the value of a given element

(iii) To multiply by a scalar value

(iv) To display the vector in the form (10,20,30………)

6.  (a) Describe briefly the features of I/O system supported by C++

(b)  Write code , including class declaration and method to implement the following using points in

C++ :

(i)  One to one association which is traversed in both direction .

(ii) One to many association which is traversed in both direction from one to many , the association is

considered ordered.

(iii) One to many association which is traversed in both direction from one to many , the association is

considered unordered.

(iv) many to many association which is traversed in both direction  , the association is considered

ordered. in one direction and unordered in the other direction.

OR

(a) What is container ? What are is different types ?

(b) Create a container class called ‘CD cabinet’ by encapsulating an array inside it. Provide method to

add a CD to first available position, remove a CD from a given position , and report the positions,

artists and titles of all CDS  in the cabinet.

Leave a Comment