Question: C++ Read the following code carefully and make it compact so that it should take input in Person and Student object through default constructors in
C++
Read the following code carefully and make it compact so that it should take input in Person and Student object through default constructors in main(). Given Code: #include class Student: public Person //syntax of writing child class { private: char coursename[30]; char section; public: void setCourseName() { cout<<"Enter Course name: "; cin>>coursename; } void setSection() { cout<<"Enter Section: "; cin>>section; } void showCourseName() const { cout<<"Show Coursename: "<
Step by Step Solution
There are 3 Steps involved in it
It seems that the question provided is incomplete The code snippet is missing the closin... View full answer
Get step-by-step solutions from verified subject matter experts
