From f69a2ad83759914f32dc1da3c32790ee85e25fbf Mon Sep 17 00:00:00 2001 From: DaviHKlein Date: Fri, 28 Oct 2022 18:42:53 -0300 Subject: [PATCH] feat(maxValue): implementa funcao maxValue --- 03-maxValue/index.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/03-maxValue/index.js b/03-maxValue/index.js index e433b31..6339696 100644 --- a/03-maxValue/index.js +++ b/03-maxValue/index.js @@ -1,4 +1,6 @@ export function maxValue(values) { // implementar logica aqui - + if(values.length > 0) + return Math.max.apply(null,values); + return 0; } \ No newline at end of file