Javascript Array mapx=function(f,t)

Description

Javascript Array mapx=function(f,t)


Array.prototype.mapx=function(f,t){
  var b=this.length,a=new Array(b);
  for(var i=0;i<b;i++){
    a[i]=f.call(t,this[i],i,this);//w ww .ja v a  2s . co  m
  }
  return a;
}



PreviousNext

Related