During my revision towards my
SCJA,I came uponm this uCertify Question in a mock exam.
Q. You work as[sic] a computer faculty. You want to take the tutorial about enumeration types in
Java. You write the following code:
What will be the output when you try to comile and run the code?
My answer: C: It will generate a compile-time error
-my answer is based on the fact that an argument to a switch statement must be compatible with type int (as they explain themselevs in the answer review)
uCertify answer: A: it will display the sky is the limit healthy wealthy and wise.
Is it some twisted logic that they reach their answer (like if the switch argument is not compatible the statement isrun anyway), or is their answer wrong outright. I appreciate some advice here!
Thanks in advance
Steve