How To Exam?

a knowledge trading engine...


Gujarat University 2008-2nd Year B.C.A Computer Application Object Oriented Programming With C++ - Question Paper

Sunday, 12 May 2013 09:10Web



Scar No.: >3 6 O

SBCA-07

March-2008

207, Objcct Oriented Programming with C++ (New Course)

Time: 3 Hours)

[Max. Marks: 70

(14)


!. Do as directed. (Any Fourteen)

1.    Variable must be declared at the beginning of the function in a C++ program. [True/False]

2.    What is the advantage of using protected data member in the class ?

3.    What is dynamic initialization ?

4.    How can we overload a function ?

5.    A dcstructor cannot be overloaded. (True / FalseJ

6.    Both, cin and getline function can be used for reading a siring. Comment.

7.    What is containership ?

8.    Whai kind of conversion mechanism is required for class to basic conversion ?

9.    What is pure virtual function ?

10.    Describe the syntax of an operaior function, tl.    What is STL?

12.    What is the use of lypeid operator ?

13.    An unhandlcd exception will cause the program to terminate. (True / False]

14.    What is the use of setflll () manipulator ?

15.    A pointer lo a base class cannot be made to point lo objects of derived class. [True / False)

16.    A class template is known as parameterized class. Comment.

II. Answer the following questions. (Any Seven)    (14)

1.    Explain return by reference.

2.    Fxplain memory management operators.

3.    What is dynamic constructor ? Give an example.

4.    Explain set_ncw_handler function.

5.    What are the differences between static .cast and dynamic_cast ?

6.    What is the need of virtual dcstructor ?

7.    What is the ambiguity that arises in multiple and diamond shaped inheritance ? How can they be removed ?

8.    How is a function template overridden for a specific data type ?

9.    Explain this pointer.

SBCA-07    1    l\T.O.




1.    Differentiate between following : (Any Three)    (06)

III. Do as directed.


(a)    Call by Value and Call by Reference

(b)    C and C-*-+

(c)    Function Overloading and Function Template

(d)    Manipulators and IOS class functions

2.    Attempt any two.    (08)

(a)    List types of errors. Explain exception handling using try statement

(b)    Explain error-handling functions for file operation.

(c)    What is friend class ? Write characteristics of friend function.

IV. I. Write short note on following: (Any Two)    (10)

(a)    Constructor in derived class

(b)    Rules for operator overloading

(c)    Inline function

2. What is inheritance ? Explain all types of inheritance.    (04)

,    OR

2. Explain memory allocation for objccts and application of static data member.

V. I. Attempt any two    *    (10)

(a)    Create Media* class containing Title and 'Price' as data members. Derived two classes form Media, one for storing the number of pages in a book and another for storing the playing time of a tape. A function display is used in all the classes to display the class contents. Use pointer of base type to call display functions defined in derived classcs.

(b)    Consider an inventory of products in a store. One way of recording the details of the products is to record their code number, total items on hand and its price. Another approach is to just spccify the item code and the value of the item in the stock. Create two classes for each type of method. Allow conversion form one type object to another type object using either constructor or casting operator function.

(c)    Create a class named String with one data member of type char *, which stores a string. Include default, parameterized and copy constructor to initialize the data member. Write a program to test this class.

2. Write a program to call member functions of class in the main function using pointer to object and pointer to the member function.    (04)

OR

2. Write a program to read aCi+ source file named 'test l.cpp and crcatc a new file named 'ktcst2.cpp that is identical to test l.cpp.

SIU7A-0?

2








Attachment:

( 0 Votes )

Add comment


Security code
Refresh

Earning:   Approval pending.
You are here: PAPER Gujarat University 2008-2nd Year B.C.A Computer Application Object Oriented Programming With C++ - Question Paper