A variable is just a letter that holds a number's place. With one letter we can describe a whole pattern at once — and that single idea is the doorway to all of algebra.
A letter that stands for a number
Look at the expression \( 3x + 2 \). The \( x \) isn't a fixed value — it's a placeholder, and we get to choose what number it stands for. Pick \( x = 1 \) and the expression is worth \( 5 \); pick \( x = 10 \) and it's worth \( 32 \). The expression itself is a recipe: "take your number, triple it, then add two." One short line of symbols captures infinitely many cases.
Notice that \( 3x \) means \( 3 \times x \) — a number written right next to a letter means multiply. In algebra we drop the times sign, because \( \times \) looks too much like the letter \( x \) and would only cause confusion.
Drag the slider to change \( x \) and watch the value of the expression follow along.
(Slide \( x \) and watch \( 3x + 2 \) take a value.)
Terms, coefficients and constants
An expression is built out of terms — the pieces separated by \( + \) and \( - \) signs. In \( 3x + 2 \) there are two terms: \( 3x \) and \( 2 \).
The term \( 3x \) has a coefficient — the number doing the multiplying — which here is \( 3 \). The other term, \( 2 \), is a constant: a fixed number with no variable attached, so it never changes no matter what \( x \) is. Reading an expression starts with naming its parts this way.
Evaluating an expression
To evaluate an expression, you substitute a chosen value for the variable and then compute, following the order of operations. Take \( 3x + 2 \) at \( x = 4 \):
\[ 3 \times 4 + 2 = 12 + 2 = 14 \]The multiplication happens before the addition, just as the order of operations demands. Negative values work the same way — you just have to mind the sign. At \( x = -2 \):
\[ 3 \times (-2) + 2 = -6 + 2 = -4 \]Wrapping the negative number in brackets keeps the multiplication honest and stops a stray sign from sneaking in.
In words A coefficient multiplies its variable, and only like terms — those with the same variable part — can be combined into one. The terms \( 3x \) and \( 5 \) live in different worlds: one carries an \( x \), the other doesn't, so they can never be added into a single term.
Like terms and simplifying
Like terms share exactly the same variable part, which means we can add or subtract them just as we would plain numbers. Their coefficients simply combine:
\[ 2x + 5x = 7x \]And we can tidy a longer expression by grouping its like pieces. The constants gather together and the \( x \)-terms gather together:
\[ 4 + 3x + 2 = 3x + 6 \]Unlike terms cannot be merged. An \( x \) and an \( x^2 \) describe different patterns, so they stay separate, and a plain number can never fold into an \( x \)-term. Trying to write \( 3x + 5 \) as a single term is the most common slip in early algebra — resist it.
The distributive law
When a multiplier sits outside a bracket, it reaches every term inside. This is the distributive law:
\[ a(b + c) = ab + ac \]So a \( 3 \) outside the bracket multiplies both pieces within it:
\[ 3(x + 2) = 3x + 6 \]The same care handles a subtraction and a coefficient already on the variable:
\[ 2(3x - 1) = 6x - 2 \]Distributing is how brackets are opened up — a tool you'll lean on constantly once equations arrive.
Turning words into expressions
The real power of variables shows up when we translate language into symbols. The first move is always the same: name the unknown with a letter.
- "Five more than twice a number" becomes \( 2n + 5 \) — double the number, then add five.
- "The cost of \( n \) tickets at \$8 each" becomes \( 8n \) — the price per ticket times how many you buy.
Choosing a letter for the unknown is the opening step of every word problem you'll ever meet. Once the words are an expression, the algebra can take over.
Tip To evaluate, substitute the value first — and if it's negative, drop it into brackets, like \( (-2) \), so the sign can't go astray. Only then follow the order of operations exactly, multiplying before you add.
- Substitute \( 4 \) in place of \( x \): the expression becomes \( 5 \times 4 - 3 \).
- Do the multiplication first: \( 5 \times 4 = 20 \).
- Then the subtraction: \( 20 - 3 \).
So \( 5x - 3 \) at \( x = 4 \) is \( 5 \times 4 - 3 = 20 - 3 = \mathbf{17} \).
- Spot the like terms. The \( x \)-terms are \( 4x \) and \( -x \); the constants are \( 7 \) and \( 2 \).
- Combine the \( x \)-terms: \( 4x - x = 3x \) (an \( x \) on its own counts as \( 1x \)).
- Combine the constants: \( 7 + 2 = 9 \).
Putting the pieces back together gives \( \mathbf{3x + 9} \).
Practice
Try each one yourself, then reveal the full solution.
1. Evaluate \( 2x + 7 \) at \( x = -3 \).
Substitute \( -3 \) for \( x \), keeping it in brackets so the sign stays safe: \( 2 \times (-3) + 7 \).
Multiply first: \( 2 \times (-3) = -6 \). Then add: \( -6 + 7 \).
So \( 2x + 7 \) at \( x = -3 \) is \( 2 \times (-3) + 7 = -6 + 7 = \mathbf{1} \).
2. Simplify \( 6a - 2a + 5 \).
The like terms here are the \( a \)-terms, \( 6a \) and \( -2a \); the \( 5 \) is a lone constant.
Combine the \( a \)-terms: \( 6a - 2a = 4a \). The constant \( 5 \) has nothing to join, so it stays.
So \( 6a - 2a + 5 = \mathbf{4a + 5} \).
3. Expand \( 2(x + 4) \).
The distributive law sends the \( 2 \) onto every term inside the bracket.
Multiply each piece: \( 2 \times x = 2x \) and \( 2 \times 4 = 8 \).
So \( 2(x + 4) = \mathbf{2x + 8} \).