React.js
Angular
Ethical Hacking
Agile
AWS
BlockChain
Cassandra
Cloud
Salesforce
Scaled Agile
TOGAF
DevOps
GIT
Jenkins
Jira
Kibana
Linux
NGINX
Ansible
Artificial Intelligence
in C++ by

What are C++ access specifiers ?

Click here to read more about DevOps

1 Answer

0 votes
by

ccess specifiers are used to define how the members (functions and variables) can be accessed outside the class.

  • Private: Members declared as private are accessible only within the same class and they cannot be accessed outside the class they are declared. Child classes are also not allowed to access private members of parent.
  • Public: Members declared as public are accessible from anywhere.
  • Protected: Only the class and its child classes can access protected members.

Related questions

Madanswer
+1 vote
asked Jul 16, 2019 in C++ by Indian
+1 vote
asked Jul 16, 2019 in C++ by Indian
+1 vote
asked Jul 16, 2019 in C++ by Indian
+1 vote
asked Jul 16, 2019 in C++ by Indian
+1 vote
asked Jul 16, 2019 in C++ by Indian
...