Here is what I came up with:
[code=php]
$family = array
Array
(
[Smith] => Array
(
[0] => Gary
[1] => Alex
[2] => Lisa
[3] => John
[4] => Nic
)
[Jones] => Array
(
[0] => Allan
[1] => Darren
[2] => Karen
[3] => Robert
[4] => Mark
)
)
echo “Is $family[Smith][2] from the Matrix?”;
It says there is a mistake on this line:
[code=php][Smith] => Array
Here is the example from the website. It does work.
[code=php]
$families = array
(
“Griffin”=>array
(
“Peter”,
“Lois”,
“Megan”
),
“Quagmire”=>array
(
“Glenn”
),
“Brown”=>array
(
“Cleveland”,
“Loretta”,
“Junior”
)
);
echo “Is ” . $families[‘Griffin’][2] .
” a part of the Griffin family?”;
Then it comes up with this and I cant seem to get that to work.
[code=php]
Array
(
[Griffin] => Array
(
[0] => Peter
[1] => Lois
[2] => Megan
)
[Quagmire] => Array
(
[0] => Glenn
)
[Brown] => Array
(
[0] => Cleveland
[1] => Loretta
[2] => Junior
)
)