forked from M3-Academy/challenge-algorithms-v2.0
9 lines
193 B
JavaScript
9 lines
193 B
JavaScript
export function maxValue(values) {
|
|
// implementar logica aqui
|
|
let maxValor = Math.max(...values);
|
|
if (values == `${[]}`) {
|
|
return 0 ;
|
|
} else {
|
|
return maxValor;
|
|
}
|
|
} |