Question OOP-ENC-0053
MediumIn C++, what does a const member function such as int get() const promise?
- A.
It can be called only once
- B.
It will not modify the object's data members
- C.
Sign up free to see the answer and a step-by-step explanation.
Popular companies
Prepare company by company
Hiring pattern, syllabus, past questions and mocks for each company.
All companiesPractice by subject
Encapsulation question
In C++, what does a const member function such as int get() const promise?
It can be called only once
It will not modify the object's data members
Sign up free to see the answer and a step-by-step explanation.
It returns a constant
It is static