challenge-algorithms-v2.0-g.../02-triangleArea/index.js

7 lines
155 B
JavaScript
Raw Normal View History

export function triangleArea(base, height) {
// your code here
2022-10-29 18:57:06 +00:00
const areaTriangle = (base * height) / 2
return areaTriangle
}
triangleArea(10, 15)