1
0
mirror of https://github.com/restoreddev/phpapprentice.git synced 2025-10-24 03:16:07 +02:00

More editing of chapters

This commit is contained in:
Andrew Davis
2019-01-06 20:56:50 -06:00
parent 9d37cb55fa
commit 504fd005bb
6 changed files with 11 additions and 11 deletions

View File

@@ -1,7 +1,7 @@
In PHP, arrays are used to store a list of items in a single variable.
There are two ways to create an array.
First, you can use the array construct to pass in values separated by commas
First, you can use the `array` construct to pass in values separated by commas
and it will return an array.
```php
<?php
@@ -25,7 +25,7 @@ echo $groceryList[1] . "\n";
```
You can also assign keys in an array using numbers or strings.
It is very common to create an array with string keys. The pattern
It is very common to create an array with string keys. The feature
is called an associative array or a map.
```php
$car = ['make' => 'Toyota', 'model' => 'Camry'];