Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

SCJP Question formation Doubt!

 
Manikandan Jayaraman
Ranch Hand
Posts: 230
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
LINK: http://www.angelfire.com/or/abhilash/Main.html

Question 24.

An Anonymous Inner class

a. Does not have a constructor
b. Can implement an interface
c. Can extend a non-final Class
d. Can implement an interface and extend a non-final class (at the same time).

Answer was a,b,c. Thats right!

It says "Doesnt have a constructor". I know that "We cannot define constructor for Anonymous Inner Class". But choice 'a' is not prefectly versed like what I have written. Right? It says, "Anonymous Inner Class does not have a constructor", which is false, as JVM provides a constructor to Anonymous Inner Class.

Can you please tell me, whether questions in actual exam will have statements very specifically written or randomly versed like this ? Thanks!
 
Marcus Green
arch rival
Rancher
Posts: 2813
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The people who create the exam questions put a great deal of effort into avoiding ambiguities, so it should be clear what the question is asking.

As you can see from the example question given it is hard to create an absolutly unambiguous question. Many times I have received questions via email which on first reading I did not understand how the sender had mis-interpreted my question. After some thought I frequently understood how easily the mis-communication might have happened.
 
Manikandan Jayaraman
Ranch Hand
Posts: 230
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Oh Marcus! Thats right!

I hope that I dont get questions that confuse me like this. I atleast expect that even if I am confused, I should be confused to the same wavelength, of the question setter, so that I will be right in answering the question correctly

After all, it is the point that you know the answer and since you are confused on the verse, you tend to give wrong answers
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic