excuse me, I'm trying to create a function to copy the array, but the function does not work, please help. thanks before
<?php
function CopyState($from, $to){
for($i=0; $i<9; $i++){
$to[$i] = $from[$i];
}
}
$a=array(1,2,3,4,5,6,7,8);
CopyState($a,$b);
echo $b[2];
?>