This question has already been answered:

Hello. There is an array in which numbers are stored. How to add them and get the sum of all the numbers in the array?

$n_itog = implode($arrst, '+'); $itog = $n_itog; echo $itog; 

$ arrst is an array with numbers. Array ([0] => 3352620 [1] => 56815)

Reported as a duplicate by members of Visman , Darth , user207618, aleksandr barakin , Sasha Omelchenko on Jun 7 '17 at 11:07 .

A similar question was asked earlier and an answer has already been received. If the answers provided are not exhaustive, please ask a new question .

    1 answer 1

    Use the standard function:

     $itog = array_sum($arrst);