Accessing Class members as below:
x.putdata();
- Private data of a class can be accessed only through the member functions of the that class .
- The format for calling a member function is
- For example the function call statement could be
x.putdata();
- Objects can communicate by sending and receiving messages.
- x.putdata() sends a message to the object x requesting it to display its contents.
Tags:
Cpp