$arr = array(1,3,5); $count = count($arr); if ($count = 0) { echo "Empty array."; } else { echo "Array consist of $count elements."; }
$arr = array(1,3,5); $count = count($arr); if ($count = 0) { // means assign 0 to $count echo "Empty array."; } else { echo "Array consist of $count elements."; }
Login in to like
Login in to comment
or Read more about PHP Quizzes
Login in to like
Login in to comment