Explain the differences between public, protected, private
and internal.
Answer Posted / rahul_kumar007
public:-
--------- It means we can access the property of public;
directly from out side of the class.
private:-
---------- it means we can't access the property of
private;
directly from out side the class.
and we can't intilizing the member var during run time
we have to use constuctor.
proctected:-
If we wnat to inherit private data member only onces.
then we make them protcted
| Is This Answer Correct ? | 10 Yes | 11 No |
Post New Answer View All Answers
What is a far pointer in c?
Function which gives a pointer to a binary trees const an integer value at each code, return function of all the nodes in binary tree.?
Is fortran still used today?
What is the purpose of the statement: strcat (S2, S1)?
Give me the code of in-order recursive and non-recursive.
What is realloc in c?
Differentiate between null and void pointers.
7-Given an index k, return the kth row of the Pascal's triangle. For example, when k = 3, the row is [1,3,3,1]. For reference look at the following standard pascal’s triangle.
Which is better between malloc and calloc?
What is p in text message?
What the advantages of using Unions?
When is a null pointer used?
What is extern variable in c with example?
What is strcpy() function?
Not all reserved words are written in lowercase. TRUE or FALSE?