JavaScript Fundamentals/Variables & Data Types
Variables & Data Types
Exercise 1 of 2
Declaring Variables
letconstvarnumberstringbooleanarithmetic
Declare the following variables:
- A
constnamedPIwith the value3.14159 - A
letnamedradiuswith the value5 - A
letnamedareathat stores the result ofPI * radius * radius
Then use console.log(area) to print the area.
javascript
⌘ EnterRun your code to see output here.