An array in PHP is an ordered mapping that maps a value to a key.
Create an array:
$array = array('apple', 'samsung', 'nokia'); //or $array = ['apple', 'samsung', 'nokia'];
Show the element of the array (starting with 0):
echo $array[0];// apple
Change the element of the array:
$array[0] = 'LG';
Add an element to the array:
$array[] = 'Xiaomi';
Remove the element from the array:
unset($array[1]);//// delete samsung