Programming-Idioms

History of Idiom 54 > diff from v1 to v2

Edit summary for version 2 :

Version 1

2015-05-06, 21:04:51

Version 2

2015-07-31, 20:46:55

Idiom #54 Compute sum of integers

Calculate the sum s of integer list x.

Idiom #54 Compute sum of integers

Calculate the sum s of integer list x.

Imports
use List::Util 'sum';
Code
$s = sum(@x);