-
What will be the output of the following PHP code ?
<?php
$n = 1;
while(++$n || --$n)
{
print $n;
}
?>
-
- 2345678......infinite time
- 12345678...........infinite time
- Error
- Nothing
- None of these
Correct Option: A
As it is || operator the second expression is not evaluated and n is always incremented, in the first case to 1.