刚才recruiter发过来一个php找错问题# JobHunting - 待字闺中
l*a
1 楼
请帮忙看看这段php代码有什么错误?
只用过php写网站,了解的不深入。
麻烦大家了。
原题描述是
what is wrong with the code and how to
fix it?
$bob = array('bob1','bob2','bob3');
foreach($bob as &$v){
$v = ucwords($v);
}
$billAndSue = array('bill1','bill2','sue','bill3');
foreach($billAndSue as $v){
if(preg_match('@[email protected]',$v)){
$bill[] = $v;
}else{
$sue[] = $v;
}
}
?>
只用过php写网站,了解的不深入。
麻烦大家了。
原题描述是
what is wrong with the code and how to
fix it?
$bob = array('bob1','bob2','bob3');
foreach($bob as &$v){
$v = ucwords($v);
}
$billAndSue = array('bill1','bill2','sue','bill3');
foreach($billAndSue as $v){
if(preg_match('@[email protected]',$v)){
$bill[] = $v;
}else{
$sue[] = $v;
}
}
?>