What will be the output of the following PHP code?
<?php
$num = "123";
if (!filter_var($num, FILTER_VALIDATE_INT))
echo("Integer is not valid");
else
echo("Integer is valid");
?>
<?php
$num = "123";
if (!filter_var($num, FILTER_VALIDATE_INT))
echo("Integer is not valid");
else
echo("Integer is valid");
?>
A. No output is returned
B. Integer is not valid
C. Integer is valid
D. Error
Answer: Option C
Join The Discussion