write a function for numbers from 1 to 10, see if even `php code example
Example 1: php odd or even
$num = 34;
if ($num % 2 == 0) {
print "It's even";
}
Example 2: php check if int is odd
$number = 15;
if ($number % 1 == 0) {
echo "It's even";
}else{
echo "oneven";
}