With fleeting pangs of vindication...
I offer the following for your consideration as another example of a POTENTIALLY SILLY ZCE question .
What combination of boolean values for $a, $b, $c, and $d will result
in the variable $number being equal to 3?
<?php
$a = null;
$b = null;
$c = null;
$d = null;
if($a && !$b) {
if(!!$c && !$d) {
if($d && ($a || $c)) {
if(!$d && $b) {
$number = 1;
} else {
$number = 2;
}
} else {
$number = 3;
}
} else {
$number = 4;
}
} else {
$number = 5;
}
?>
While there IS a correct answer...
In the context of the question the code block provided is represented as being
generally viable, however at least 40% of the code is wholly untenable.
In all permutations of "true or false" for $a, $b, $c, and $d,
only 4 of 16 will satisfy the first condition, and only one of those will satisfy the second condition
(e.g. the correct answer to an otherwise flawed question/problem).
There are NO possible permutations that will satisfy either the third or fourth conditions.
Now if that isn't silly enough, be honest and ask yourself if you think that you,
or anyone else short of some peculiarly gifted savant (think Rain Man here)
could be realistically expected to "see" the permutations in their heads
(or scribble them on a scrap of paper even -- assuming that is allowed)
and come up with a correct answer in under -- say -- 5 minutes time?
Missing the obvious var_dump component of the answer to the question presented in my initial post (duh),
by the time I got to said question I was already kind of ticked-off at the "silliness" of many of the test
questions that had preceded it and perhaps rushed to dismiss it as silly as well.
Nonetheless ... assuming the practice tests are representative of the actual ZCE Test,
I stand by my original assertion that the ZCE test is largely "rooted in a bunch of silliness."
Anyone???