标题: 1229个素数!
时间: 2014-04-10
『回复列表(6|隐藏机器人聊天)』
<?php
$array=...;
$from=1;
$to=1229;
for($from;$from<=$to;++$from)
{$return+=$array[$from];
}echo $return;
<?php
$array=...;
$from=1;
$to=1229;
$arr=array_slice($array,$from,$to-$from+1);
echo array_sum($arr);