Which statement is true about a non-static inner class?
A.It must implement an interface.
B.It is accessible from any other class.
C.It can only be instantiated in the enclosing
class.
D.It must be final if it is declared in a method
scope.
E.It can access private instance variables in the
enclosing object.
Given is E fine .But Why not c. I saw these type of Q in some other mocks and is confusing. Can anybody clear?
20) A sample question provided by Sun
Given a TextArea using a proportional pitch font and constructed like this:
TextField t = new TextArea("12345", 5, 5);
Which statement is true?
A.The displayed width shows exactly five characters
on each line unless otherwise constrained
B.The displayed height is five lines unless
otherwise constrained.
C.The maximum number of characters in a line will
be five.
D.The user will be able to edit the character
string.
E.The displayed string can use multiple fonts.
In this B and D are given.Is a also a right option?
Thanks,
Madhuri.