About Question enthuware.jwpv6.2.928 :
Moderator: admin
About Question enthuware.jwpv6.2.928 :
About option 1...It is considered wrong...but I think it is possible to define "method local inner class" and put the method there...
-
- Site Admin
- Posts: 10388
- Joined: Fri Sep 10, 2010 9:26 pm
- Contact:
Re: About Question enthuware.jwpv6.2.928 :
I see what you mean. Technically, you are right but that will make the question too complicated for the exam. I think it is good that you pointed it out here but I am not sure if it is a good idea to make it a right option.
May be the option itself can be removed?
May be the option itself can be removed?
Re: About Question enthuware.jwpv6.2.928 :
Yes, I agree it might become "too scjp type of question"
))))
So maybe what you suggest is a proper way to solve this

So maybe what you suggest is a proper way to solve this

-
- Posts: 13
- Joined: Thu Jul 11, 2013 11:22 pm
- Contact:
Re: About Question enthuware.jwpv6.2.928 :
The correct answers:
2.<%! public void m1() { ... } %>
4.<%! public void m1() { ... }; %>
The difference is one has ";" and the other does not. How can both be right?
2.<%! public void m1() { ... } %>
4.<%! public void m1() { ... }; %>
The difference is one has ";" and the other does not. How can both be right?
-
- Site Admin
- Posts: 10388
- Joined: Fri Sep 10, 2010 9:26 pm
- Contact:
Re: About Question enthuware.jwpv6.2.928 :
Because semi colon is redundant here.
Who is online
Users browsing this forum: No registered users and 1 guest