It seems that mutator and accessor functions defeat the purpose of making the member variables private. Why is this not so?
What will be an ideal response?
The mutator functions can filter data and control the way data members are set. For example, you (as class author) can exclude illegal data. With accessor functions you (as class author) can allow the client to see just the variables you want seen, in the format in which you want them seen.
Computer Science & Information Technology
You might also like to view...
The character that separates tokens is known as a(n) ____________.
a. sentinel b. article c. delimiter d. separator
Computer Science & Information Technology
Transcoding can cause loss of ____, so avoid transcoding an already transcoded video file.
A. clarity B. format C. focus D. quality
Computer Science & Information Technology