Explain protected and public in c++, C/C++ Programming

Explain protected, public, private in C++?

These are three access spaecifiers in C++.

- Public - Here data members and functions are accessible outside the class.

- Protected - Data members and functions are available to derived classes only.

- Private - Data members and functions aren't accessible outside the class.

 

 

Posted Date: 9/7/2013 2:30:37 AM | Location : United States







Related Discussions:- Explain protected and public in c++, Assignment Help, Ask Question on Explain protected and public in c++, Get Answer, Expert's Help, Explain protected and public in c++ Discussions

Write discussion on Explain protected and public in c++
Your posts are moderated
Related Questions
program for factorial

The purpose of this assignment is to familiarize you with the notion of encapsulation as well as some aspects of IP and ICMP. Write your programs in C or C++. They will be grade

c program for boardcolouring

pseudocode for gregorian calendar

Should I call a destructor explicitly on a local variable?

Study the following  class diagram, additional information  and answer  the  questions that follow: MovieTicket movieName: string TicketPrice: doub

C Program for FUNCTION OF COPY ONE STRING IN OTHER STRING #include stdio.h> #include conio.h> int copy(char a[],char b[]); void main() {           char a[100],b[

1 Aims The main purpose of the assignment is to let you practice the following programming techniques: perform operations on pointers to basic and more complex types;

salotion of programes