Skip to content
VUBuddy

CS201 Final Term Solved File 5 by Team Hadi

Introduction to Programming PDF 1.1 MBUpdated 23 Oct 2026
Final term past paper CS201 Final Term Solved File 5 by Team Hadi PDF 1.1 MB
vubuddy.com
Type
Final term past paper
Course
CS201 Introduction to Programming
Size
PDF 1.1 MB
Updated
23 Oct 2026
Free download 0 of 3 used today
Download free · 1.1 MB

You get 3 free files a day on the website. Add the Chrome extension for 30 a day.

Unlimited downloads in the Android app Get it free on Google Play

Preview text

Text from pages 1, 2, 3 of 32. Download the file for all 32 pages.

CS201 FINAL TERM · PAST PAPER BY · TEAM HADI · LAHORE

  1. For binary member operators, operands on the ________ drives (calls) the operation.
  2. Left
  3. Right
  4. Both left and right
  5. None of the given
  6. We cannot increment ________.
  7. pointers
  8. arrays
  9. references
  10. variables
  11. We can ________ pointer.
  12. increment
  13. decrement
  14. reassign
  15. all of the given
  16. We can ________ references.
  17. increment
  18. decrement
  19. reassign
  20. None of the given

Q5. What will be the correct syntax for the following function call?

float add (int &);

  1. add(int x);
  2. add(&x);
  3. add(x);
  4. add(*x);
  5. An instance of a class is called ________.
  6. structure
  7. data type
  8. object
  9. member function

7. The ________ is called automatically when an object destroys

  1. destructor
  2. constructor
  3. main program
  4. default constructor
  5. The destructor is used to ________.
  6. allocate memory
  7. deallocate memory
  8. create objects
  9. allocate static memory
  10. ________ data isn't accessible by non-member functions or outside classes.
  11. Public
  12. private
  13. Static
  14. Globally declared
  15. Member functions of the class ________ main program.
  16. are not accessible
  17. are accessible from
  18. are defined within the
  19. are private to

11. Overloading means :

  1. Using the same name to perform multiple tasks or different tasks depending on the situation.
  2. Using the different name to perform multiple tasks or different tasks depending on the situation
  3. Using the same name to perform multiple tasks or same tasks depending on the situation
  4. Using the same name to perform difficult tasks or complex tasks and it does not depend on the situation
  5. The main advantage of function overloading is ________.
  6. The program becomes portable
  7. The program becomes complex
  8. The function becomes inline
  9. The program becomes more readable
  10. You cannot overload the ________ operator.
  11. ? :
  12. *
  13. /
  14. ++

14. In C++, a variable can be declared anywhere in the program this will increase

  1. writability
  2. readability
  3. portability
  4. efficiency
  5. Memory allocated from heap or free store ________.
  6. can be returned back to the system automatically
  7. can be allocated to classes only
  8. cannot be returned back unless freed explicitly using malloc and realloc
  9. cannot be returned back unless freed explicitly using free and delete operators
  10. We cannot use ________ pointer for storing and reading data from it.
  11. 'NULL
  12. integer
  13. double
  14. zero
  15. The dynamic memory allocation uses ________ whereas static memory allocation uses ________.
  16. heap , stack
  17. stack , lists
  18. array , stack
  19. classes , array

Q18. What will be the output of the given code?

#include #define MAX( A, B ) ((A) > (B) ? (A) : (B)) · void main() { · int i, x, y; · x = 23; · y = 45; · i = MAX( x++, y++ ); · // Side-effect: // larger value incremented twice

cout << "x = " << x << " y = " << y << '\n';

  1. x=23 y=45
All CS201 files →
CS201 Introduction to Programming All CS201 handouts, past papers, quizzes and MCQs in one place. Open course page

Get more out of VUBuddy, for free

Android app Free on Google Play
  • Unlimited downloads
  • The explanation behind every MCQ answer
  • Study offline on slow data
Get the Android app
Chrome extension Free on the Chrome Web Store
  • 30 downloads a day instead of 3
  • Sign in and buy Pro Semester here
Add to Chrome

One Pro Semester membership works in both the extension and the app.