Explain the differences between public, protected, private
and internal.
Answers were Sorted based on User's Feedback
Answer / avinash
public means we can access the code or data in public that
is visible to others.
protected means the code or data can be within the system
and,or it has no access to it.and it is not available.
private means it can be accessesed only by the person who
has the access or key to it.
| Is This Answer Correct ? | 1 Yes | 0 No |
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 |
Do you know what is a programing language ?
two progs are given. one starts counting frm 0 to MAX and the other stars frm MAX to 0. which one executes fast.
While compiling a c program,graphics header files are not including in my program..eg: <graphics.h>,what may be the problem...is there any environment settings exists.
write a C and C++ programme to implement the A,bubble sort B,quick sort C,insertion sort D,sequential search E,binary search
hOW Can I add character in to pointer array of characters char *a="indian"; ie I want to add google after indian in the char *a
how many header file is in C language ?
44 Answers College School Exams Tests, CTS, IBM, IMS, Infosys, ME, Sign Solutions, Wipro, XVT,
How does #define work?
Whats s or c mean?
what is the difference between i++ and ++i?
Why functions are used in c?
Is main a keyword in c?
write a program whose output will be- 1 12 123 1234