aspose file tools*
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes Finally abrupt return Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Soft Skills this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Reply locked New topic
Author

Finally abrupt return

Vikrant Sahdev
Ranch Hand

Joined: May 31, 2007
Posts: 58
I found this question on a Mock exam for SCJP1.5:




I think the answer should be A1 but its A4. I think its A1 bcos even though return exits finally block abruptly,it still compiles without error.

What do you guys think ?
Also do you think there would be any difference in answer,if compiled with 1.4 or 1.5 ?


Coming soon... www.javatales.com
Peter Mularien
Author
Ranch Hand

Joined: Sep 06, 2007
Posts: 84
There's no compiler error when using the 1.4.2 or 1.6.0 compiler. I agree with you that it should print 3. Do they give any indication as to what the compiler error would be?


Author, Spring Security 3 (the Book), Packt Publishing, 2010
SCJP, OCP
Burkhard Hassel
Ranch Hand

Joined: Aug 25, 2006
Posts: 1274
double thread closed.
answer here please:
http://www.coderanch.com/t/265314/java-programmer-SCJP/certification/Finally-abrupt-return
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Finally abrupt return