MSU B.Sc Computer Science 3rd Semester Programming in C++ Important Questions November 2026
Manonmaniam Sundaranar University B.Sc Computer Science 2nd Year 3rd Semester Programming in C++ Important Questions November 2026
Manonmaniam Sundaranar University – B.Sc Computer Science – Second Year – Third Semester – Programming in C++ – November 2026 Semester Examination.
Students preparing for the Manonmaniam Sundaranar University November 2026 Semester Examination can use the following important questions for Programming in C++. This study material covers all five units, including Part A (1 Mark), Part B (5 Marks), Part C (8 Marks), important C++ programs and last-minute revision topics.
Note: These questions are provided for examination preparation and revision. They are not an official or confirmed university question paper.
SUBJECT DETAILS
University: Manonmaniam Sundaranar University
Course: B.Sc. Computer Science
Year: Second Year
Semester: Third Semester
Subject: Programming in C++
Examination: November 2026
Question Pattern: Part A, Part B and Part C
Topics for Revision
- this pointer
- Constructors and destructors
- Inheritance (types and programs)
- Operator overloading
- Key concepts or advantages of OOP
- Friend function, static members, array of objects, type conversion, abstract class
- File handling (stream classes, modes, random access)
- Templates, exception handling, new/delete, virtual base class
UNIT I
Part B (5 Marks)
- Advantages of OOP
- Inline functions with example
- Function overloading with syntax and example
- Compare
continueandbreak - For / while / do-while loops with examples
- Structure of a C++ program, or a program to add two numbers using
cinandcout
Part C (8 Marks)
- Key concepts of OOP with examples (objects, classes, abstraction, encapsulation, inheritance, polymorphism, dynamic binding, message passing)
- Decision-making and control statements: if-else, switch-case, goto, break, continue, with syntax and examples
- Looping statements in C++
- C++ declarations (variable and function declarations)
UNIT II
Part B
- Static data members and static member functions
- Friend function with example
- Array of objects
- Classes and objects, including defining member functions inside and outside the class
- Rules or characteristics of constructors, and the destructor
- Bit fields and classes
- Overloading member functions
- Characteristics of a const object
Part C
- Constructors and destructors: types (default, parameterized, copy, overloaded) with programs, plus constructors with static members
- Friend function: need, characteristics, and a program to find the maximum of two numbers
- Array of objects program, such as total and average marks of 5 students
- Define class and object with an example
- Programs: complex number addition using constructors, copy a string using constructors, power of a number with default arguments
UNIT III
Part B
- Overloading unary operators (++, −−, −)
- Rules for operator overloading
- Overloading operators with friend functions
- Type conversion: basic to class, class to basic, class to class
- Virtual base class: what it is and why it's used
- Abstract class with example
Part C
- Types of inheritance with diagrams and examples (single, multilevel, multiple, hierarchical, hybrid, multipath)
- Program: employee pay bill using inheritance
- Unary and binary operator overloading with a program, or a
+operator program for string concatenation - Virtual base class program, or abstract class program
- Compare multiple and multilevel inheritance
- Type conversion operators with examples
UNIT IV
Part B
thispointer with examplenewanddeleteoperators and dynamic memory allocation- Pure virtual function
- Pointer to objects or pointer to class
- Read the contents of an array using a pointer
- Virtual functions: rules and example
Part C
- Virtual functions and polymorphism: compile-time vs run-time, early vs late binding, with program
- Pointers: declaration, initialization, pointer to object, pointers to base and derived classes
thispointer in detail, plus the program to find the elder of two persons usingthis- Dynamic memory allocation and dynamic objects using
newanddelete - Types of arrays, and array of classes
- Dynamic object binding
UNIT V
Part B
- File modes with example (
ios::in,out,app,ate,binary,trunc) - File stream classes (
ifstream,ofstream,fstream) - Templates: syntax of function and class templates
- Exception handling with try, throw and catch
- Random access functions (
seekg,seekp,tellg,tellp) - String class: any five functions, or a program to copy one file to another
- Manipulators
Part C
- File stream classes and operations, with a program to write and read text using
ofstreamandifstream - Random access in files with a
seekg()andtellg()program - Exception handling mechanism with a program
- Templates: function and class templates, sorting or swapping with templates
- Binary and ASCII files
- String class attributes and operations
- Handling file I/O errors
Dark Horse Topics
These are additional topics from your syllabus for revision:
- Pointers to derived and base classes
- Memory models
- String class
- Manipulators
- Binary vs ASCII files
- Bit fields
Part A Quick Facts (Easy 10 Marks)
- Execution starts at
main(). - A destructor is written with
~. - A default constructor takes 0 parameters.
- A class is the blueprint of an object.
newallocates memory dynamically anddeletefrees it.- Pure virtual function:
virtual void f() = 0; - Abstract classes can't be instantiated.
thisis passed as a hidden argument to non-static member functions.do-whileruns at least once.- Inline functions are expanded at compile time.
- Virtual functions use late (run-time) binding.
- A friend function overloading a binary operator takes 2 arguments, and one overloading a unary operator takes 1.
- Multipath inheritance causes duplication, and a virtual base class fixes it.
ofstreamwrites,ifstreamreads, andfstreamdoes both.seekg()/tellg()work on the get (read) pointer, andseekp()/tellp()on the put (write) pointer.- The
templatekeyword defines templates, andtry,throw,catchhandle exceptions. <<is the insertion operator and>>is the extraction operator.- Encapsulation binds data and functions together.
PART A: 1-Mark MCQs (10 × 1 = 10 Marks)
Each is written as question → answer, so learn the answers, because the options get reworded or reordered.
UNIT I: Introduction, Control Structures, Functions
- Data type supported in C++ but not in C → bool
- Execution of a C++ program starts from → main() function
- Which is not a fundamental data type in C++ → string
- Statement used for input in C++ → cin
- Loop that checks the condition at the end → do-while
- Loop executed at least once → do...while
- Control structure for multi-way branching → switch-case
- When is an inline function expanded → Compile time
- Inline functions increase speed by reducing → function call overhead
- The
<<operator is called the → insertion operator - The
>>operator is called the → extraction operator - Header file needed for
cinandcout→ iostream - Scope resolution operator → ::
- Statement used to exit a loop immediately → break
- Same function name with different parameters is called → function overloading (compile-time polymorphism)
- Concept of OOP that binds data and functions together → Encapsulation
- Concept that lets the same function be used in different ways → Polymorphism
- The
continuestatement → skips the rest of the current iteration
UNIT II: Classes, Objects, Constructors
- A class is a ______ for creating an object → blueprint
- Correct way to declare an object of a class → classname object;
- Number of parameters of a default constructor → 0 (zero)
- Destructor is preceded by the symbol → ~ (tilde)
- Group of objects stored in a single variable → Array (of objects)
- Constructor that handles static data member initialization → Default
- Statement that creates a destructor call for a const object → called when the object goes out of scope
- Default access specifier of a class → private
- A constructor has the same name as the → class
- Return type of a constructor → none (no return type, not even void)
- Keyword that declares a friend function → friend
- Static data members are shared by → all objects of the class
- A static member function can access → only static members
- A friend function is called → like a normal function, without an object and dot operator
- Bit fields specify → the number of bits a member occupies
- Order of destructor calls compared with constructors → reverse order
- Constructor that creates an object from another object of the same class → Copy constructor
- Can a destructor be overloaded → No
UNIT III: Operator Overloading, Inheritance
- Binary operator among the options → + (addition), since
++,--and*(dereference) are unary - Deriving new classes from existing classes → Inheritance
- Derived class inheriting from more than one base class → Multiple inheritance
- Derived class with only one base class → Single inheritance
- Inheritance that may duplicate grandparent members → Multipath inheritance (fixed by a virtual base class)
- Class that cannot be instantiated → Abstract class
- Arguments needed to overload a binary operator using a friend function → Two
- Narrowing conversion → double to int
- Keyword used to overload an operator → operator
- Arguments for a binary operator overloaded as a member function → One
- Arguments for a unary operator overloaded as a member function → Zero
- Dummy
intargument in an operator function indicates → postfix form (a++) - Operators that cannot be overloaded →
::,.,.*,?:,sizeof - Basic-to-class conversion is done using a → constructor
- Class-to-basic conversion is done using a → conversion (casting) operator function
- Derived class that is also a base for another class → Multilevel inheritance
- Many classes derived from one base class → Hierarchical inheritance
- Combination of two or more types of inheritance → Hybrid inheritance
- Default inheritance mode for a
class→ private - Members accessible in derived classes but not outside → protected
UNIT IV: Pointers, Dynamic Memory, Polymorphism
thispointer is passed as a hidden argument to → all non-static member functions- Operator for dynamic memory allocation → new
- Operator used to destroy dynamically created objects → delete
- Delete operator is used to → deallocate dynamically created memory
- Declare a pure virtual function → virtual void f() = 0;
- Binding associated with virtual functions → Dynamic (late/run-time) binding
- In late binding the function call is resolved at → run time
- A virtual function is a member of the ______ class → Base
- Compile-time polymorphism is implemented using → Templates (also function and operator overloading)
- Declare an array of 10 integers → int arr[10];
- Declare an array of 10 objects of class Student → Student arr[10];
- Dynamic constructors → allow dynamic memory allocation during object creation
- General declaration of a pointer variable → datatype *pointervariable;
- Address-of operator → &
- Dereferencing operator → *
- Operator to access members through an object pointer → -> (arrow)
thispointer points to → the current (calling) object- A base class pointer can point to → a derived class object
- Early binding is also called → static / compile-time binding
- Runtime polymorphism is achieved using → virtual functions
- Pointer that stores no address → NULL / nullptr
- Memory allocated by
newcomes from the → heap (free store) - Array index starts from → 0
- Freeing a dynamically allocated array → delete[]
UNIT V: Files, Templates, Exceptions, Strings
- Stream class used to read from files → ifstream
- Stream class used to write into a file → ofstream
- Class used for both reading and writing → fstream
- Operation that reads or writes data in order → Sequential
- Keyword used to define templates → template
- Keyword used to catch exceptions → catch
- Abnormal behavior of a program should be written under the ______ block → try
- Validity of template parameters → inside that block only (the template declaration or definition)
- Asynchronous exceptions are caused by → events beyond the program's control (e.g. keyboard interrupts)
- Purpose of
ofstream→ to write data to a file - Header file for file handling → fstream
- Mode to append data at the end of a file → ios::app
- Mode to open a file for reading → ios::in
- Mode to open a file for writing → ios::out
- Mode used for binary files → ios::binary
seekg()moves the → get (read) pointerseekp()moves the → put (write) pointertellg()returns the → current get pointer positiontellp()returns the → current put pointer position- Function that checks end of file → eof()
- Function that closes a file → close()
- Keyword that raises an exception → throw
- Handler that catches any type of exception → catch(...)
- Header file for the string class → string
- Function that returns the length of a string → length() (or size())
- Header file for manipulators like
setw→ iomanip - Manipulator for a new line plus buffer flush → endl
A Few Tricky Ones
- The paper had two ambiguous questions: "Which class handles output streams?" (the options included ofstream but not
ostream) and "Which function moves the file pointer?" (seekgandseekpboth fit). If you see these, pick the option that best fits the exact wording. - Questions such as "Which operator allocates memory?" can show
malloc,callocandnewtogether. The C++ operator is new, becausemallocis a C function. coutandcinare objects, not statements or keywords, but the question papers still call them "statements". Answer as the paper expects.
Important Topics to Revise Before Examination
- Constructors and destructors
- Inheritance and its types
- Operator overloading
- this pointer
- Friend functions and static members
- File handling and stream classes
- Templates and exception handling
- Virtual functions and abstract classes
- Dynamic memory allocation
- Random access file functions
Preparation Tips for November 2026 Examination
- Revise all five units carefully.
- Practise the important C++ programs by writing them yourself.
- Study the definitions and key concepts of Object-Oriented Programming.
- Prepare the constructors, destructors and inheritance topics thoroughly.
- Understand the differences between virtual functions and pure virtual functions.
- Practise file handling programs and random access functions.
- Revise Part A questions and answers before the examination.
- Use your prescribed syllabus, textbooks and classroom notes for complete preparation.
Conclusion
We hope these Manonmaniam Sundaranar University B.Sc Computer Science Second Year Third Semester Programming in C++ Important Questions for November 2026 will help students prepare effectively for their semester examinations.
Study all five units, practise C++ programs and revise the important questions regularly. All the best for your November 2026 semester examination!
For more university important questions, study materials, previous year question papers and educational updates, keep visiting:
www.mheducationalblog.in
Educational Disclaimer
This article is published for educational and examination preparation purposes only. The questions and answers are provided as revision material and are not an official or confirmed Manonmaniam Sundaranar University November 2026 examination paper. Students are advised to refer to the latest official university syllabus, prescribed textbooks and faculty guidance for complete preparation.
Keywords: Manonmaniam Sundaranar University Important Questions November 2026, MSU B.Sc Computer Science 3rd Semester, Programming in C++ Important Questions, B.Sc CS 2nd Year, C++ 5 Marks Questions, C++ 8 Marks Questions, C++ 1 Mark MCQs, MSU Study Materials.
Labels: Manonmaniam Sundaranar University, B.Sc Computer Science, Programming in C++, November 2026, Important Questions, Third Semester, MSU Study Materials.