php中怎样用foreach改变数组的值?
为什么这样的代码无法改变数组中的值呢?$table_exchange=array(1,2,3,4,5,6,7,8);foreach($table_exchangeas$b...
为什么这样的代码无法改变数组中的值呢?
$table_exchange=array(1,2,3,4,5,6,7,8);
foreach ($table_exchange as $b=>$c){
$c="Week_".$c;
}
echo $table_exchange[0]; 展开
$table_exchange=array(1,2,3,4,5,6,7,8);
foreach ($table_exchange as $b=>$c){
$c="Week_".$c;
}
echo $table_exchange[0]; 展开
1个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询