What are the differences between public, private, and
protected access?
Answer Posted / kalpana.y
Private is used for intialization of variables
eg:
int p,r;
public is used for function name
eg:
void display();
protected is used for void main()
eg:
void main()
class c;
Is This Answer Correct ? | 24 Yes | 86 No |
Post New Answer View All Answers
What does scope resolution operator do?
which operator is used for performing an exponential operation a) > b) ^ c) none
When does a name clash occur in c++?
How come you find out if a linked-list is a cycle or not?
Incase of a function declaration, what is extern means?
Describe the advantages of operator overloading?
What c++ library is string in?
Is c++ a programming language?
What is c++ and its uses?
Am studying basic c++ programming, have been given the following assignment. Design a linear program to calculate the maximum stress a material can withstand given a force and a diameter of a circle. To find the required area pi should be defined. Have most of the program sorted out but am at a loss as to how to show the calculations required. Can anyone help?
What is constructor c++?
What are dynamic type checking?
What are c++ storage classes?
What is a modifier in c++?
What is meant by iomanip in c++?