forked from M3-Academy/challenge-algorithms-v2.0
10 lines
214 B
JavaScript
10 lines
214 B
JavaScript
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);
|
|
}
|
|
} |