Core Java Interview questions


Total available count: 646
Subject - Java Technologies
Subsubject - Core Java

What is visibility of protected access modifier?

Methods and fields declared as protected can only be accessed by the subclasses in other package or any class within the package of the protected members class. The protected access specifier cannot be applied to class and interfaces.




Next 5 interview question(s)

1

What is the visibility of public access modifier?

2

What is the visibility of private access modifier?

3

How many types of access modifiers are available in java, mention them?

4

What is returned by the method toString() in java?

5

 Which method is invoked by the garbage collector before object is being garbage collected?