You made it to the end of the lesson! High five. 🙌
Here is a review of the lesson:
- A variable represents a particular piece of your computer’s memory that has been set aside for you to use to store, retrieve, and manipulate data.
- Variables are declared using the
- Constants are declared using the
- Swift basic data types include:
- Single equals sign
- Arithmetic operators include
- Compound assignment operators include
Optional: The body mass index (BMI) is commonly used by health and nutrition professionals to estimate human body fat in populations.
It is computed by taking the individual’s weight in kilograms (kg) and dividing it by the square of their height in meters (m²):
Complete the BMI.swift program.
(To skip, just click Run.)