challenge-algorithms-v2.0-m.../03-maxValue/index.js

10 lines
214 B
JavaScript
Raw Normal View History

export function maxValue(values) {
// implementar logica aqui
if(values.length == 1){
return values[i];
}else if(values.length == []){
return 0;
}else{
return Math.max.apply(null, values);
}
}