By now you may be able to solve equations with one or two variables. In this section, we are going to explore the steps involved in writing commands to solve equations. This skill is useful for programming a computer to display a web site properly or controlling a robot.

Solve for x: x + 7 = 10

Commands

Step 1: Write the equation → x + 7 = 10

Step 2: Undo addition → x + 7 – 7 = 10 – 7

Step 3: Do the arithmetic → x = 3

Step 4: Underline the answer → __ x = 3 __

Solve for x: ¼x = 17

Step 1: Write the given equation → ¼ • x = 17

*To do the problem without a fraction, convert the fraction into a decimal by commanding the computer to “do the arithmetic arithmetic.”

Step 2: Do the arithmetic → 0.25

Step 3: Undo the multiplication → __0.25x__ = __17 __

0.25 = 0.25

Step 4: Do the arithmetic → x = 68

Step 5: Underline the answer → __x = 68 __

An algorithm means __solve the equation__

Step 1: Write the given

Step 2: Do the first instruction that applies

-Do the arithmetic

-Undo the addition

-Undo the subtraction

-Undo the multiplication

-Undo the division

Step 3: Keep on doing this until there is nothing to do

Step 4: Underline the answer

This method is usually successful. The reason we use the phrase “Undo the addition” instead of “add this number” is because if you use “add” you must specify a number, and sometimes this number can be very long. It is better not to type the number and instead use “undo the addition.”

- CyberProf(TM)