Answer Posted / nimish singh
One that can be modified by the class even when the object of the class or the member function doing the modification is const.
Understanding this requirement implies an understanding of C++ const, which many programmers do not have. I have seen large class designs that do not employ the const qualifier anywhere. Some of those designs are my own early C++ efforts. One author suggests that some programmers find const to be such a bother that it is easier to ignore const than to try to use it meaningfully. No wonder many programmers don't understand the power and implications of const. Someone who claims to have enough interest in the language and its evolution to keep pace with the ANSI deliberations should not be ignorant of const, however.
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Why we use #include iostream in c++?
Which should be more useful: the protected and public virtuals?
What are c++ manipulators?
Why cout is used in c++?
How can you differentiate between inheritance and implementation in c++?
Which bit wise operator is suitable for checking whether a particular bit is on or off?
Which software is used to run c++ program?
Explain "const" reference arguments in function?
Define vptr.
Is it legal in c++ to overload operator++ so that it decrements a value in your class?
Does improper inheritance have a potential to wreck a project?
Explain Memory Allocation in C/C++ ?
Explain the differences between private, public and protected and give examples.
If a base class is an adt, and it has three pure virtual functions, how many of these functions must be overridden in its derived classes?
Do you know what are pure virtual functions?