Reigel's demo page

HTML

bvg

JavaScript

Array.prototype.sum = function() {
  return (! this.length) ? 0 : this.slice(1).sum() +
      ((typeof this[0] == 'number') ? this[0] : 0);
};

x = [1.2, 3.4, 5.6]
    
alert(x.sum());