Browse papers
A

Section A: Long Answer Questions

Attempt any TWO questions.

3 questions·10 marks each
1long10 marks

What is object-oriented programming? Explain the basic concepts of OOP: class, object, encapsulation, inheritance and polymorphism with suitable examples.

oop-concepts
2long10 marks

What is a constructor? Explain different types of constructors (default, parameterized and copy constructor) with a C++ program for each.

constructor
3long10 marks

What is operator overloading? Write a C++ program to overload the binary '+' operator to add two complex numbers using a member function.

operator-overloading
B

Section B: Short Answer Questions

Attempt any EIGHT questions.

9 questions·5 marks each
4short5 marks

Differentiate between procedural and object-oriented programming.

oop-concepts
5short5 marks

What is a destructor? When is it called?

destructor
6short5 marks

Explain the use of the scope resolution operator (::) in C++.

syntax
7short5 marks

What is inline function? Write its syntax with an example.

inline-function
8short5 marks

Differentiate between call by value and call by reference.

functions
9short5 marks

What is a namespace in C++?

namespace
10short5 marks

Explain the new and delete operators.

memory
11short5 marks

What is data hiding? How is it achieved in C++?

encapsulation
12short5 marks

Write a short note on the default arguments in a function.

functions