Download PTU I. K. Gujral Punjab Technical University (IKGPTU) MCA (Master of Computer Applications) 2020 December 1st Sem 72708 Object Oriented Programming In C++ Previous Question Paper
Roll No.
Total No. of Pages : 02
Total No. of Questions : 08
MCA (2015 to 2018) (Sem.?1)
OBJECT ORIENTED PROGRAMMING IN C++
Subject Code : MCA-102
M.Code : 72708
Time : 2 Hrs. Max. Marks : 30
INST RUCT IONS T O CANDIDAT ES :
1 .
Attempt any FIVE question (s), ea ch que stion c arrie s 6 ma rks .
1.
What is classes and what are its various types of members? Give relevant examples to
explain.
2.
Write a class to represent a vector (a series of float values). Include member functions to
perform the following tasks :
a) To create the vector
b) To modify the value of a given element
c) To multiply by a scalar value
d) To display the vector in the form (10, 20, 30,...) Write a program to test your class.
3.
What is a constructor and destructor? What is the use of default & copy constructors? Is a
constructor mandatory for a Class.? Explain by giving examples in each case.
4.
What are the various bit wise operators? Explain with example.
5.
What do you understand by inheritance? Give its various types and access mechanisms.
6.
Explain how base class member functions can be invoked in a derived class if the derived
class also has a member function with the same name.
7.
Write a program in C++ to overload the +, ?, ?, % operator to find the addition,
subtraction, multiplication and division of Complex numbers.
8.
Write a program to copy the content of a data file to another file. Make use of the exception
handling conditions also.
1 | M-72708
(S6)-23
Note: Any student found attempting answer sheet from any other person(s), using
incriminating material or involved in any wrong activity reported by evaluator shall be
treated under UMC provisions.
Student found sharing the question paper(s)/answer sheet on digital media or with any
other person or any organization/institution shall also be treated under UMC.
Any student found making any change/addition/modification in contents of scanned copy of
answer sheet and original answer sheet, shall be covered under UMC provisions.
2 | M-72708
(S6)-23
This post was last modified on 14 February 2021