var arr = [23,42,34,234,123,12,31,23,234,34,534,534,234,23,4];
var max = arr.reduce(function(a , b){
return b > a ? b : a;
});
console.log(max);
var arr = [23,42,34,234,123,12,31,23,234,34,534,534,234,23,4];
var max = arr.reduce(function(a , b){
return b > a ? b : a;
});
console.log(max);