求数组平均值

327 阅读1分钟
Array.prototype.average = function(){
    //this 要操作的数组
    var t = eval(this,join('+'))/this.length;
}