The document contains three tasks related to Object-Oriented Programming (OOP) in C++. Task 1 demonstrates the use of a constructor and destructor in a Student class, Task 2 introduces accessor functions for setting and getting student ID and name, and Task 3 illustrates the use of the 'this' pointer for member variable assignment. Each task includes code snippets and basic validation for input values.
Download as TXT, PDF, TXT or read online on Scribd
0 ratings0% found this document useful (0 votes)
0 views
CS304 Lecture 9 Programs
The document contains three tasks related to Object-Oriented Programming (OOP) in C++. Task 1 demonstrates the use of a constructor and destructor in a Student class, Task 2 introduces accessor functions for setting and getting student ID and name, and Task 3 illustrates the use of the 'this' pointer for member variable assignment. Each task includes code snippets and basic validation for input values.