Answered step by step
Verified Expert Solution
Question
1 Approved Answer
am on the ex rght now ts very urgent hurry up (30)1-Why do we use virtual base classes? Explain. (40)2- Write the program code for
am on the ex rght now ts very urgent hurry up
(30)1-Why do we use virtual base classes? Explain. (40)2- Write the program code for overloading the operator - for class myclass which is declared below. Overload the -- operator for both postfix decrement and prefix decrement. (note: you must decrement every data member of myclass class) declerations of the prefix and postfix decrement operaters are given below. class myclass {private:double a,b,c,d; public://constructor myclass (double u,double x, double v,double y) {a=u;b=x;c=v;d=y;} //constructor myclass operator--0;// declaration of prefix decrement myclass operator-(int notused);// declaration of postfix dec. }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