Question: (, ); Question 3 [20 marks]: We have a class called electronic_device that shows the information of an electronic device with two attributes: serial_number and

 (, ); Question 3 [20 marks]: We have a class called

electronic_device that shows the information of an electronic device with two attributes:

(, ); Question 3 [20 marks]: We have a class called electronic_device that shows the information of an electronic device with two attributes: serial_number and year_built. The classes phone and laptop are inherited from electronic_device. We have another class called smartphone that inherits from phone class. The cade is provided below: #include using namespace std; class electronic device protected: string serial_number; int year built; public: ( /"getters and setters/ virtual void print coutprint(); delete e; return 0; } 3-d) [5 marks] Write the code for creating a dynamic object of smart phone class with these initial values: serial_number: "samsung123", year_built: 2020, number of camera:3, number_of_apps: 15. Then explain when you create these object which constructors and in which order they are called. (, ); Question 3 [20 marks]: We have a class called electronic_device that shows the information of an electronic device with two attributes: serial_number and year_built. The classes phone and laptop are inherited from electronic_device. We have another class called smartphone that inherits from phone class. The cade is provided below: #include using namespace std; class electronic device protected: string serial_number; int year built; public: ( /"getters and setters/ virtual void print coutprint(); delete e; return 0; } 3-d) [5 marks] Write the code for creating a dynamic object of smart phone class with these initial values: serial_number: "samsung123", year_built: 2020, number of camera:3, number_of_apps: 15. Then explain when you create these object which constructors and in which order they are called

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!