Answer Posted / ranganathkini
A class can be marked by the "private" access specifier only
if its a nested member of another class.
Top level classes cannot be marked as "private". Hence you
can have private classes in a java file but they must be
nested inside another class.
| Is This Answer Correct ? | 208 Yes | 16 No |
Post New Answer View All Answers
What is the difference between hashset and treeset in java?
Is string a class in java?
What is the largest number a double can hold?
What is the java reflection api? Why it’s so important to have?
Explain the importance of finally over return statement?
What is the map interface in java programming?
What is a Hash Table? What are the advantages of using a hash table?
Is integer immutable in java?
What are recursive functions? Give some examples?
What is the intersection and union methods?
Which class represents the socket that both the client and server use to communicate with each other?
Can we declare register variable as global?
What is use of super keyword?
Is age a discrete variable?
What is the difference between procedural and object-oriented programs?