Let us discuss about the function
is_array() is_array() - Check whether the given variable is an array
Syntax:
bool is_array ( mixed var )
Example:
$arrColor = array('Red', 'Blue', 'Green');
echo is_array($arrColor) ? 'It is an array' : 'It is not an array'; Output: It is an array