$ends = array_fill(0, {0}, 0);
for ($i = 0; $i < {0}; $i++) {{
    $ends[$i] = $n_svs[$i] + $starts[$i];
}}
