//摘自php5手册模简陆$a = array(2, 4, 6, 8);echo "sum(a) = " . array_sum($a) . "\n"旦顷;$b = array("a" => 1.2, "b" => 2.3, "c"咐纳 => 3.4);echo "sum(b) = " . array_sum($b) . "\n";?>
做一个简单循环就好.