Caddell Prep Access Menu

Declaring Variables

  • Join today & get access to 1,000's of practice problems

In this video we will be learning how to declare variables in word problems.

For example:

The length of a rectangle is 5 units longer than the width. If the perimeter is 22 units, how long is the width?

Let w = width

Let w + 5 = length

Perimeter Formula:  P=2l+2w

w + w + w + 5 + w + 5 = 22  w = 3

Video-Lesson Transcript

Let’s go over declaring variables.

When we have word problems, we may start writing down equations based on the given then try to solve it.

But if we lost track of what the variables are, it’s highly possible to get an incorrect answer.

Normally, declaring variables is like this:

Let x equal a number of something.

Or let y equal the width of a shape.

Let’s have an example.

A book store charges \$20 for the first book and \$15 for each additional book. Write an expression to represent the total cost of buying any number of books.

Let’s start with declaring the variables.

Let x = number of books.

Now we need to know the total cost based on the information given.

Now, we have

cost = \$20 + \$15 times number of additional books

Let’s use x in this equation.

cost = \$20 + \$15 (x - 1)

x is the number of additional books. So we subtract the first book from cost x.

For example:

We bought 10 books. The cost is going to be 20 + 15 \times9 additional.

It’s not 10 because the first book is valued at \$20.

Declaring Variables

Let’s take a look at another example.

The length of a rectangle is 5 units longer than the width. If the perimeter is 22 units, how long is the width?

Let w = width

Let w + 5 = length

Now, let’s draw a rectangle.

Label the two as “w” for width and label the length as “w + 5“.

The perimeter is

w + w + w + 5 + w + 5 = 22

Since we already labeled the rectangle, it’ll be easier.

Let’s continue solving

4w + 10 = 22

Then subtract 10 to both sides of the equation.

4w + 10 - 10 = 22 - 10

This becomes

4w = 12

To solve “w“, let’s divide both sides by 4

\dfrac{4w}{4} = \dfrac{12}{4} w = 3

Now, let’s go back to the problem and substitute the value of w.

If w = width = 3,

then the w + 5 = length = 8.