Question 9: Consider the following: Class Course { protected: long CRN public: Course( long c ); }; // end of class #include #include "Courses.h" using namespace std; Class Student { private: const string university; string name; long studID ; vector stdCourses ; static int totalStudents; Public: Student (); Student string uni,string n, long id, vector c ); }; // end of class //Write the Default constructor here: (everytime a Student is created, total llstudents increases by one) IWrite the Overloaded constructor here: (everytime a Student is created, total llstudents increases by one) // Instantiate the static variable totalStudents to 100 like you would in your /Student.cpp file here // Create an object of type Student using default constructor here // Create an object of type Student using overloaded constructor here /Write a void add To Courses ( Course c ) function that will add to student's vector lof Courses

Microsoft Visual C#
7th Edition
ISBN:9781337102100
Author:Joyce, Farrell.
Publisher:Joyce, Farrell.
Chapter10: Introduction To Inheritance
Section: Chapter Questions
Problem 12RQ
icon
Related questions
Question
Question 9: Consider the following:
Class Course
{
protected:
long CRN
public:
Course( long c );
}; // end of class
#include <string>
#include "Courses.h"
using namespace std;
Class Student
{
private:
const string university;
string name;
long studID ;
vector<Course> stdCourses ;
static int totalStudents;
Public:
Student ();
Student string uni,string n, long id, vector<Courses> c );
}; // end of class
//Write the Default constructor here: (everytime a Student is created, total
llstudents increases by one)
Transcribed Image Text:Question 9: Consider the following: Class Course { protected: long CRN public: Course( long c ); }; // end of class #include <string> #include "Courses.h" using namespace std; Class Student { private: const string university; string name; long studID ; vector<Course> stdCourses ; static int totalStudents; Public: Student (); Student string uni,string n, long id, vector<Courses> c ); }; // end of class //Write the Default constructor here: (everytime a Student is created, total llstudents increases by one)
IWrite the Overloaded constructor here: (everytime a Student is created, total
llstudents increases by one)
// Instantiate the static variable totalStudents to 100 like you would in your
/Student.cpp file here
// Create an object of type Student using default constructor here
// Create an object of type Student using overloaded constructor here
/Write a void add To Courses ( Course c ) function that will add to student's vector
lof Courses
Transcribed Image Text:IWrite the Overloaded constructor here: (everytime a Student is created, total llstudents increases by one) // Instantiate the static variable totalStudents to 100 like you would in your /Student.cpp file here // Create an object of type Student using default constructor here // Create an object of type Student using overloaded constructor here /Write a void add To Courses ( Course c ) function that will add to student's vector lof Courses
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 3 steps

Blurred answer
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Microsoft Visual C#
Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,