Download PTU (I.K. Gujral Punjab Technical University Jalandhar (IKGPTU) ) MBA (Master of Business Administration) 2020 March 4th Sem 71400 Programming In C++ Previous Question Paper
Roll No. Total No. of Pages : 03
Total No. of Questions : 15
MBA (2016 to 2017) (Sem.?4)
PROGRAMMING IN C++
Subject Code : MBA-986
M.Code : 71400
Time : 3 Hrs. Max. Marks : 60
INSTRUCTION TO CANDIDATES :
1. SECTION-A contains SIX questions carrying FIVE marks each and students has
to attempt any FOUR questions.
2. SECTION-B consists of FOUR Subsections : Units-I, II, III & IV. Each Subsection
contains TWO questions each carrying EIGHT marks each and student has to
attempt any ONE question from each Subsection.
3. SECTION-C is COMPULSORY carrying EIGHT marks.
SECTION-A
Q1. Differentiate between break and continue statement. Give example of each.
Q2. Define Pointer with suitable example. Highlight the difference between the pointer and
reference variable.
Q3. What is an inline function? Discuss advantages, disadvantages of inline function.
Q4. What is constructor overloading? What is benefit of constructor overloading?
Q5. Describe in brief the role of seekp(), seekg(), tellp(), tellg() in file handling.
Q6 What is virtual function? What is the need of virtual functions?
SECTION-B
UNIT-I
Q7 a) Compare the use of the if - else statement with the use of the ? : operator. In
particular, in what way can the ? : operator be used in place of an if - else statement.
b) What is the purpose of the switch statement? How does this statement differ from the
other decision making statements?
FirstRanker.com - FirstRanker's Choice
1 | M-71400 (S13)-2056
Roll No. Total No. of Pages : 03
Total No. of Questions : 15
MBA (2016 to 2017) (Sem.?4)
PROGRAMMING IN C++
Subject Code : MBA-986
M.Code : 71400
Time : 3 Hrs. Max. Marks : 60
INSTRUCTION TO CANDIDATES :
1. SECTION-A contains SIX questions carrying FIVE marks each and students has
to attempt any FOUR questions.
2. SECTION-B consists of FOUR Subsections : Units-I, II, III & IV. Each Subsection
contains TWO questions each carrying EIGHT marks each and student has to
attempt any ONE question from each Subsection.
3. SECTION-C is COMPULSORY carrying EIGHT marks.
SECTION-A
Q1. Differentiate between break and continue statement. Give example of each.
Q2. Define Pointer with suitable example. Highlight the difference between the pointer and
reference variable.
Q3. What is an inline function? Discuss advantages, disadvantages of inline function.
Q4. What is constructor overloading? What is benefit of constructor overloading?
Q5. Describe in brief the role of seekp(), seekg(), tellp(), tellg() in file handling.
Q6 What is virtual function? What is the need of virtual functions?
SECTION-B
UNIT-I
Q7 a) Compare the use of the if - else statement with the use of the ? : operator. In
particular, in what way can the ? : operator be used in place of an if - else statement.
b) What is the purpose of the switch statement? How does this statement differ from the
other decision making statements?
2 | M-71400 (S13)-2056
Q8. Define the terms:
1. Data encapsulation
2. Data hiding
3. Data abstraction
4. Inheritance
5. Polymorphism
6. Objects
7. Class
8. Member function
UNIT-II
Q9. How is a pointer variable declared? What kind of information is stored by a pointer
variable? Differentiate between call by value and call by address with suitable example.
Q10. Explain the concept of passing one dimensional, two dimensional arrays through
functions with suitable example of each.
UNIT-III
Q11. Explain the visibility of base class members for the access specifiers: private, protected
and public while creating the derived class and also explain the syntax for creating
derived class.
Q12 What is the role of constructor and destructor? Write a C++ program to define a suitable
parameterized constructor with default values for the class distance with data members
feet and inches
UNIT-IV
Q13. Define Function Overloading. Write a C++ program to define three overloaded functions
to swap two integers, swap two floats and swap two doubles.
Q14. Define the term file. Write a C++ program to read text file and perform following
operation
1. Display count of character in file
2. Display count of new line in file.
FirstRanker.com - FirstRanker's Choice
1 | M-71400 (S13)-2056
Roll No. Total No. of Pages : 03
Total No. of Questions : 15
MBA (2016 to 2017) (Sem.?4)
PROGRAMMING IN C++
Subject Code : MBA-986
M.Code : 71400
Time : 3 Hrs. Max. Marks : 60
INSTRUCTION TO CANDIDATES :
1. SECTION-A contains SIX questions carrying FIVE marks each and students has
to attempt any FOUR questions.
2. SECTION-B consists of FOUR Subsections : Units-I, II, III & IV. Each Subsection
contains TWO questions each carrying EIGHT marks each and student has to
attempt any ONE question from each Subsection.
3. SECTION-C is COMPULSORY carrying EIGHT marks.
SECTION-A
Q1. Differentiate between break and continue statement. Give example of each.
Q2. Define Pointer with suitable example. Highlight the difference between the pointer and
reference variable.
Q3. What is an inline function? Discuss advantages, disadvantages of inline function.
Q4. What is constructor overloading? What is benefit of constructor overloading?
Q5. Describe in brief the role of seekp(), seekg(), tellp(), tellg() in file handling.
Q6 What is virtual function? What is the need of virtual functions?
SECTION-B
UNIT-I
Q7 a) Compare the use of the if - else statement with the use of the ? : operator. In
particular, in what way can the ? : operator be used in place of an if - else statement.
b) What is the purpose of the switch statement? How does this statement differ from the
other decision making statements?
2 | M-71400 (S13)-2056
Q8. Define the terms:
1. Data encapsulation
2. Data hiding
3. Data abstraction
4. Inheritance
5. Polymorphism
6. Objects
7. Class
8. Member function
UNIT-II
Q9. How is a pointer variable declared? What kind of information is stored by a pointer
variable? Differentiate between call by value and call by address with suitable example.
Q10. Explain the concept of passing one dimensional, two dimensional arrays through
functions with suitable example of each.
UNIT-III
Q11. Explain the visibility of base class members for the access specifiers: private, protected
and public while creating the derived class and also explain the syntax for creating
derived class.
Q12 What is the role of constructor and destructor? Write a C++ program to define a suitable
parameterized constructor with default values for the class distance with data members
feet and inches
UNIT-IV
Q13. Define Function Overloading. Write a C++ program to define three overloaded functions
to swap two integers, swap two floats and swap two doubles.
Q14. Define the term file. Write a C++ program to read text file and perform following
operation
1. Display count of character in file
2. Display count of new line in file.
3 | M-71400 (S13)-2056
SECTION-C
Q15. Create a class named Student with the following specifications :
An instance variable named name to hold a student?s name
An instance variable named rollno to hold a student?s roll number
An instance variable named scores to hold a student?s 5 exam spores.
Avoid input() function that reads 5 integers and saves them to scores
An int calculateTotalScore() function that returns the sum of the student?s scores.
A void search() function to search a student record based on name and print its record i.e
name,rollno, scores .
Inside main() function create array of objects and call all functions to simulate the
program
(Note : take necessary assumptions where required)
NOTE : Disclosure of Identity by writing Mobile No. or Making of passing request on any
page of Answer Sheet will lead to UMC against the Student.
FirstRanker.com - FirstRanker's Choice
This post was last modified on 22 March 2020