I am experimenting the questions from Oracle for the Java 7 Associate certification. The application for the windows is created by Oracle Press (probably). They've sent it to me with the Book.
Currently, I have one question which application says "wrong answer", when I say that all answers are correct. Could someone explain this? The question is that Inner classes and inner interfaces can be both private and protected, but the explanation says classes and interfaces can't be. Please find question and explanation below. I hope this is the right place to ask this kind of questionJ.
Question
The private and protected access modifiers can be used with which entities? (Choose all that apply.)
Answers:
A: Classes
B: Interfaces
C: Constructors
D: Methods
E: Data Members
Correct Answers from Oracle:
C: Constructors
D: Methods
E: Data members
EXPLANA TION: C, D, and E. The private and protected access modifiers can be used with constructors, methods, and data members. A and B are incorrect. The private and protected access modifiers cannot be used with classes and interfaces.