Aryan PrajapatKnowledge Contributor
What are the C++ access modifiers?
What are the C++ access modifiers?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Questions | Answers | Discussions | Knowledge sharing | Communities & more.
The access restriction specified to the class members( whether it is member function or data member) is known as access modifiers/specifiers.
Access Modifiers are of 3 types:
Private – It can neither be accessed nor be viewed from outside the class
Protected – It can be accessed if and only if the accessor is the derived class
Public – It can be accessed or be viewed from outside the class