In C++ class SaleItem { public: double getprice(); void setprice(double); void setName(string); string getName(); double TotalItemsPrice(int); private: double price; string name; }; In the class declaration above, what is the name of the class? Which lines have member access specifiers? Which lines contain data members of the class?

Microsoft Visual C#
7th Edition
ISBN:9781337102100
Author:Joyce, Farrell.
Publisher:Joyce, Farrell.
Chapter10: Introduction To Inheritance
Section: Chapter Questions
Problem 9RQ
icon
Related questions
Question
100%

In C++

class SaleItem
{
public:
double getprice();
void setprice(double);
void setName(string);
string getName();
double TotalItemsPrice(int);
private:
double price;
string name;
};

  1. In the class declaration above, what is the name of the class?
  2. Which lines have member access specifiers?
  3. Which lines contain data members of the class?
  4. Which lines contain accessor functions?
  5. Which lines contain mutator functions?
Expert Solution
steps

Step by step

Solved in 2 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,