"/> ">
Home > Article > Backend Development > Get the length of an array - count() function
Get the length of the array - count() function
count() function is used to return the length of the array (number of elements):
Example
<?php $cars=array("Volvo","BMW","SAAB"); echo count($cars); ?>