Source Code:
(back to article)
<?php $number = 5; if ($number > 0) { if ($number % 2 == 0) { echo "$number is a positive even number"; } else { echo "$number is a positive odd number"; } } else { echo "$number is a negative number"; } ?>
Result:
Report an issue