0% found this document useful (0 votes)
14 views4 pages

BCS-031 (4)

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)
14 views4 pages

BCS-031 (4)

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/ 4

No.

of Printed Pages : 4 BCS–031

BACHELOR OF COMPUTER

APPLICATIONS

(BCA)

Term-End Examination

June, 2024

BCS–031 : PROGRAMMING IN C++

Time : 3 Hours Maximum Marks : 100

Note : Question No. 1 is compulsory and carries

40 marks. Attempt any three questions from

the rest.

1. (a) Differentiate between structured and

object oriented programming paradigms. 5

P. T. O.
[2] BCS–031

(b) Explain the use of private and protected

access specifiers. 5

(c) What do you mean by runtime

polymorphism ? How is it achieved ? 5

(d) What is the inline member function ? Why

do we declare the member function as

inline ? 5

(e) Explain the working of for loop with the

help of an example C++ program. 5

(f) What is an object ? How is it passed as a

parameter ? 5

(g) Explain seekg( ), seekp( ), tellg( ), tellp( )

functions of stream classes. 5

(h) How are the constructors of base class

invoked by derived class constructors ?

Discuss with reference to parameterized

constructors. 5
[3] BCS–031

2. (a) What are static data member and static

member function ? Write a program to

explain the benefit of using static members

in C++. 10

(b) Differentiate between function overloading

and function overriding. Explain with the

help of C++ program. 10

3. (a) What do you mean by template function ?

What are its benefits ? Write down code for

a template function to swap values of two

numbers. 10

(b) Write a program to add and subtract two

instances of a complex number class

(having data members real and

imaginary). Make use of a friend function

for the same. The class should make use of

a parameterized constructor for creating

and initializing the data members. 10

P. T. O.
[4] BCS–031

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

(a) Exception handling

(b) Inheritance

(c) Relational and logical operators

(d) File stream classes

5. (a) How can a class be made abstract ? Take a

suitable example to demonstrate the

behaviour of a pure virtual function. 10

(b) Write a program to overload + = and

* = operator for complex number class

(data members are real and imaginary for

the class). 10

BCS–031

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy