Skip to main content
โ† Back to Mathematics samples
๐ŸงฎMathematicsยท20 minยทSample Lesson

Variables and Expressions

A rideshare app charges a $2.50 base fee plus $1.75 for every mile you travel. For a 3-mile trip that's $2.50 + $1.75(3) = $7.75. For an 8-mile trip, it's $2.50 + $1.75(8) = $16.50. Rather than recalculating from scratch every time, you can write one formula, cost = 2.50 + 1.75m, and plug in any number of miles, m. That formula is an algebraic expression, and m is a variable, the tool this whole lesson is built around.

What You'll Learn

What a variable is and why letters stand in for unknown or changing numbers. How to evaluate an expression by substituting a number for a variable. How to combine like terms to simplify expressions. How to translate a real-world situation into an algebraic expression.

Variables, Terms, and Expressions

A variable is a letter, most commonly x, n, or y, that represents a number we don't know yet or that can change. An expression is a combination of numbers, variables, and operations, like 4x + 7 or 3n - 2. Unlike an equation, an expression has no equals sign and no single fixed answer; its value depends entirely on what number you substitute for the variable. In the expression 4x + 7, the pieces separated by addition or subtraction are called terms: 4x is one term (a variable term with coefficient 4) and 7 is another term (a constant, since it never changes).

Evaluating Expressions by Substitution

To evaluate an expression, replace the variable with a specific number and follow the order of operations (parentheses, exponents, multiplication/division, addition/subtraction, left to right). Example: evaluate 5x - 3 when x = 4. Step 1: Substitute: 5(4) - 3. Step 2: Multiply first: 20 - 3. Step 3: Subtract: 17. So when x = 4, the expression 5x - 3 equals 17. Change x to 10, and the same expression gives 5(10) - 3 = 47, a completely different value, because that's the whole point of a variable.

Combining Like Terms

Like terms have the exact same variable raised to the exact same power, like 3x and 5x, or 2y^2 and -7y^2. You combine like terms by adding or subtracting their coefficients while keeping the variable part unchanged. Example: simplify 6x + 3 - 2x + 9. Group like terms: (6x - 2x) + (3 + 9). Combine: 4x + 12. Note that 4x and 12 are NOT like terms (one has a variable, one doesn't), so this expression is already fully simplified.

Common Mistake

Students often try to combine 4x and 12 into 16x. You can only combine terms that share the identical variable part. A variable term and a constant term can never be merged into one.

Translating Real Situations into Expressions

Algebra becomes powerful when you use it to model real life. A phone plan costing $30 per month plus $0.10 per text becomes 30 + 0.10t, where t is the number of texts. A rectangular garden that is 4 feet longer than it is wide has a width w and a length w + 4, so its perimeter is 2w + 2(w + 4), which simplifies to 4w + 8. Key phrases to watch for: "more than" or "increased by" usually means addition; "less than" means subtraction (and reverses order: "5 less than x" is x - 5, not 5 - x); "times" or "product of" means multiplication; "per" or "for each" signals a coefficient attached to a variable.

Match each phrase to its correct algebraic expression.

Terms

7 more than a number n
5 less than a number n
Twice a number n, plus 3
The product of 6 and a number n

Definitions

n - 5
2n + 3
6n
n + 7

Drag terms onto their definitions, or click a term then click a definition to match.

โ“

Evaluate the expression 3x^2 - 4 when x = 3.

โ“

A gym membership costs $20 to join plus $15 per month. Which expression represents the total cost after m months?

๐ŸŽฏ

Price Your Own Business Plan

Invent a simple business idea (a lemonade stand, a dog-walking service, a phone-repair side hustle). Decide on a one-time or fixed cost and a per-unit cost (per cup, per walk, per repair), then write an algebraic expression for total cost or total earnings using a variable for the quantity. Evaluate your expression for three different quantities (for example, 5, 20, and 50 units) and show your substitution work for each. Present your expression and your three calculated totals.

Want to keep learning?

Sign up for free to access the full curriculum โ€” all subjects, all ages.

Start Learning Free