adspace
Answer Posted / Seema Pal
In C++, there are three access specifiers: private (denoted by 'private:' or just 'private'), protected (denoted by 'protected' or 'protected:'), and public (denoted by 'public').nn1) Private: Variables and functions marked as private can only be accessed within the class.n2) Protected: Variables and functions marked as protected can be accessed by the member functions of the class, its derived classes, and friend classes.n3) Public: Variables and functions marked as public can be accessed from anywhere in the program.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers