Exercise 7 · Chapter: FunctionsRequired+50 XP
Area Calculator
Write two functions:
rectangleArea(w, h)— returns width times heightcircleArea(r)— returns 3.14 times r squared
Then print the results:
Rectangle: 20 Circle: 12.56
Need a hint?
3 available · costs 5 XP each
javascript
Output
Run your code to see the output here.