<?php $miArray = [3, 4, "pepe", 5, false]; $otro = array(3, 4, 5); var_dump($miArray); var_dump($otro); $miArray[] = "otro elemento"; $miArray[] = "y otro más"; var_dump($miArray); $asociativo = ["a" => 5, "b" => 6, "c" => 12]; foreach ($asociativo as $clave => $valor) { echo $clave . " - " . $valor . "<br/>"; } $multi = [ [1, 2, 3], [4, 5, 6], [7, 8, 9] ]; echo $multi[1][1]."<br/>"; for ($i = 0; $i < count($multi); $i++) { for ($j = 0; $j < count($multi[$i]); $j++) { echo $i . " - " . $j . " : " . $multi[$i][$j] . "<br/>"; } } foreach ($multi as $f=>$filas){ foreach($filas as $c=>$valor){ echo $f." - ".$c." : ".$valor."<br/>"; } } print_r($multi); ?>