Answer Posted / janet
Public: Any thing declared as public can be accessed from
any where.
Private: Any thing declared as private can't be seen
outside of it's class.
Protected: Any thing declared as protected can be accessed
by classes in the same package and subclasses in the other
packages.
Default modifier: can be accessed only to classes in the
same package.
| Is This Answer Correct ? | 11 Yes | 4 No |
Post New Answer View All Answers
Does java trim remove newline?
What is ‘is-a ‘ relationship in java?
What are the two main uses of volatile in Java?
What is class??
How do I know if java is installed?
What is methodological framework?
What is the difference between stream and buffer?
What are the approaches that you will follow for making a program very efficient?
What is difference between core java and java ee?
What does nullpointerexception mean?
what is bmg file and how to create that files?what will it contailn?
Explain about object oriented programming and its features?
Can we use synchronized block for primitives?
What are java packages? What's the significance of packages?
I want to re-reach and use an object once it has been garbage collected. How it's possible?