This site is mobile accessible. Press the "Tap Here" button to use a different font-size.


Smartphone icons created by Freepik - Flaticon

PHP Arrays

count() Function

3

<?php
// define $cars array
$cars=array("Volvo","BMW","Toyota");

// count and display the number of elements in the array
echo count($cars);
?>