From c32afac72202a4d238156a7f5945f3a76cc93f71 Mon Sep 17 00:00:00 2001 From: Maria Carolina Date: Mon, 31 Oct 2022 15:35:04 -0300 Subject: [PATCH] Calculo area do triangulo --- 02-triangleArea/index.js | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/02-triangleArea/index.js b/02-triangleArea/index.js index 7628fcd..d972967 100644 --- a/02-triangleArea/index.js +++ b/02-triangleArea/index.js @@ -1,3 +1,7 @@ export function triangleArea(base, height) { - // your code here -} \ No newline at end of file + return (base * height) / 2; +} + +console.log(triangleArea(3,5)); +console.log(triangleArea(5,5)); +console.log(triangleArea(2,5));