Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Objective: Students will practice inheritance and polymorphism in C++. Assignment a- Create a Point class. A Point class has two double variables: x_coord, and y_coord.
Objective: Students will practice inheritance and polymorphism in C++. Assignment a- Create a Point class. A Point class has two double variables: x_coord, and y_coord. a. (1 pts) Create default and overloaded constructors. b. (1 pt) Create all accessors and mutators of the class. b- Create a shape class which has a Point object as a protected member variable. a. (2 pts) Create default and overloaded constructors.. b. (1 pt) Create all setters and mutators. c (1 pt) Create a virtual void Print ( ) f function to print the point on the screen. In main: (3 pt) Create a vector pointers to Shape objects. .Use a while loop to add 10 objects to the object Shape. a. b. (1 pt) Print all objects in the vector on the screen.*
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started