Exercise
Weekend
## Warm Up

## Code

### Variables Practice

**Goal:** In the Variables lesson, we learned:

- Variables, in JavaScript, are written in lower camelcase
- Variables are set using the
`var`

keyword - Variables can be used in arithmetic

Practice creating and utilizing variables by completing the exercises listed below. Variables are a fundamental building block of programming; so begin getting comfortable with them now!

- When are
`let`

and`const`

used? What do they mean - and how are they different from`var`

? - How can we use a variable after we've defined it?

Here are a few exercises for you to practice using variables:

- Set a variable called
`someName`

equal to your name. Put your name in quotation marks. - Display the value of
`someName`

in the console. - Change the value of
`someName`

. - Set a variable called
`favoriteNumber`

equal to your favorite number. - Calculate what your favorite number divided by 2 is.
- Set another variable called
`michaelsFavorite`

equal to`13`

. - Change the value of
`michaelsFavorite`

to`7`

. - Subtract your favorite number from mine.
- Change the value of my favorite number to be 26 times its current value.

Lesson 8 of 61

Last updated October 12, 2020