Page 1 of 1

About Question enthuware.ocajp.i.v7.2.864 :

Posted: Mon Mar 04, 2013 10:25 pm
by satar
Struggled with this one because option one talks about "unexpected user inputs", which is when something out of the ordinary happens. Kind of think this one is a bit on the gray side.

Re: About Question enthuware.ocajp.i.v7.2.864 :

Posted: Tue Apr 09, 2013 11:47 am
by baxhuli
Till now I knew that Exceptions were there to make sure to make the program not to crash if smth unexpected happened and not just for "logging purposes". We can log unexpected user behaviors even through "if-else if-else" but there is no other mechanism to make the program not to crash if something goes wrong. I understand that this is what Oracle wants but it does not make much sense.

Re: About Question enthuware.ocajp.i.v7.2.864 :

Posted: Thu Feb 20, 2014 3:02 pm
by billclar
This is a bit subjective as there are four correct answers.

Logging is a separate concept from Exceptions.
Unexpected user inputs are a reason for IllegalArgumentException.

Re: About Question enthuware.ocajp.i.v7.2.864 :

Posted: Thu Oct 16, 2014 3:46 pm
by FruityPebbles
I agree that the answers are somewhat subjective. You could make an argument for any of the given answers.

Re: About Question enthuware.ocajp.i.v7.2.864 :

Posted: Thu Oct 16, 2014 7:08 pm
by admin
Yes, it is a bit subjective and that is what the explanation says as well.

Re: About Question enthuware.ocajp.i.v7.2.864 :

Posted: Mon Feb 15, 2016 11:27 pm
by olograph
The only reason this question would help is:
if you haven't been warned (100 times) already that some exam questions are going to be unclear­
or
if a question with very similar syntax would show up in the exam.

Otherwise, it (re-creating potential confusing sentences) is a waste of everyone's time.

Re: About Question enthuware.ocajp.i.v7.2.864 :

Posted: Fri Feb 19, 2016 10:34 am
by NickWoodward
its purpose is to recreate the exam. if that includes confusing or obscure statements, so be it.

Re: About Question enthuware.ocajp.i.v7.2.864 :

Posted: Thu Jul 27, 2017 5:11 am
by redvee78
I understand what admin says about this question, but in my opinion it's a bad question. If the exam has such questions, then I personally value the exam less.

Re: About Question enthuware.ocajp.i.v7.2.864 :

Posted: Tue May 14, 2019 6:46 am
by flex567
I don't understand why is this not correct:
that the VM uses to exit the program when something unexpected happens.
Based on exceptions the JVM closes the thread that is running the program. or?

Re: About Question enthuware.ocajp.i.v7.2.864 :

Posted: Tue May 14, 2019 7:02 am
by admin
There may be multiple threads running inside a JVM. Terminating a thread doesn't mean shutting down the JVM.

Re: About Question enthuware.ocajp.i.v7.2.864 :

Posted: Tue May 14, 2019 7:18 am
by flex567
Ok but I still don't understand why this is not a correct option?
that the VM uses to exit the program when something unexpected happens.

Re: About Question enthuware.ocajp.i.v7.2.864 :

Posted: Tue May 14, 2019 7:25 am
by admin
because that is not what happens. Java Exceptions is NOT a mechanism that the VM uses to exit the program when something unexpected happens.