- Foundation
- About 15 min
- 5 practice questions
What an algorithm is: column addition step by step
Describe an algorithm as a precise list of basic steps, follow the column addition algorithm with carries exactly as written, explain why it gives the right sum, and see why it is far faster than counting.
If something looks wrong, please tell us.
By the end of this lesson you can
- Say what an algorithm is and what its 'basic steps' are.
- Carry out the column addition algorithm exactly as written, including the final carry.
- Explain why the algorithm is correct and why it needs far less work than counting.
The word algorithm is everywhere today: in phones, maps and online shopping. But algorithms are much older than computers. You have been using one since primary school, every time you added two numbers in columns. This chapter looks at algorithms as mathematics: how to write them precisely, how to know they are correct, and how to make them faster.
From counting to a method
Young children add 5 and 7 by drawing 5 dots, then 7 more, and counting all 12. That works, but imagine adding 586 and 947 that way: over 1,500 dots! Instead we write the numbers one below the other, lined up from the right, and add one column at a time, carrying when a column total reaches 10 or more. This method is an algorithm: a step-by-step procedure that solves every problem of a certain kind.
An algorithm is a precise, step-by-step procedure for solving a whole class of problems. It is built from basic steps we already know how to do, such as adding two single digits.
The column addition algorithm
- Write the two numbers one below the other so that their digits line up from the right (units under units, tens under tens, and so on). Where a number has no digit in a column, treat the digit as 0.
- Set carry to 0. Start with the rightmost column.
- Add the two digits in the column and the carry. If the sum is less than 10, write it below and set carry to 0. If it is 10 or more, write its units digit below and set carry to 1.
- Move one column to the left and repeat step 3 until there are no more columns.
- If carry is 1 at the end, write 1 at the far left of the answer.
One column of the addition algorithm
- Add the two digits and the carry
- Sum less than 10? Write the sum; carry becomes 0
- Sum 10 or more? Write the units digit; carry becomes 1
- Move one column left Repeat until no columns remain, then write any final carry
Worked example 1: 586 + 947
Units: 6 + 7 + 0 = 13. Write 3, carry 1.
Tens: 8 + 4 + 1 = 13. Write 3, carry 1.
Hundreds: 5 + 9 + 1 = 15. Write 5, carry 1.
No more columns, and carry is 1, so write 1 on the left.
Answer: 1533.
Without step 5 the answer would come out as 533, which is wrong. Every step matters, and the steps must be followed exactly as written.
Worked example 2: numbers of different lengths
40758 + 963. Line up from the right, treating the missing digits of 963 as 0 (so it is 00963).
Units: 8 + 3 = 11. Write 1, carry 1.
Tens: 5 + 6 + 1 = 12. Write 2, carry 1.
Hundreds: 7 + 9 + 1 = 17. Write 7, carry 1.
Thousands: 0 + 0 + 1 = 1. Write 1, carry 0.
Ten-thousands: 4 + 0 + 0 = 4. Write 4.
Answer: 41721. Check: 41721 − 963 = 40758.
Why is the carry never more than 1? The largest a column can total is 9 + 9 + 1 = 19, which is less than 20, so at most one ten is carried.
Why the algorithm is correct
Whenever we give an algorithm, we must also justify it. Each number is a sum of units, tens, hundreds and so on: 586 = 5 hundreds + 8 tens + 6 units, and 947 = 9 hundreds + 4 tens + 7 units. Adding column by column adds units to units, tens to tens and hundreds to hundreds. When the units make 13, that is 1 ten and 3 units, so the 1 ten is 'carried' to the tens column, where it belongs. The same happens at every column. To add decimals, we line up the decimal points instead of the right-hand ends, and the same reasoning applies to tenths and hundredths.
How much work does it save?
| Numbers being added | Dots to count (about) | Time counting | Columns | Time by columns |
|---|---|---|---|---|
| Two 2-digit numbers, e.g. 33 + 27 | 60 | 1 minute | 2 | 30 seconds |
| Two 3-digit numbers, e.g. 334 + 272 | 600 | 10 minutes | 3 | 45 seconds |
| Two 4-digit numbers, e.g. 3347 + 2729 | 6000 | over 1.5 hours | 4 | 1 minute |
Each extra digit makes the numbers about 10 times bigger, so counting takes about 10 times longer. The column method needs only one more column. The work of counting grows with the value of the numbers; the work of the algorithm grows with the number of digits. This difference is what makes a good algorithm valuable.
Key takeaways
- An algorithm is a precise sequence of basic steps that solves a whole class of problems.
- Column addition works because it adds units to units, tens to tens and so on, carrying each new ten to the next column.
- The carry is never more than 1, since 9 + 9 + 1 = 19.
- Counting effort grows with the size of the numbers; column addition grows only with the number of digits.
Check your understanding
-
1. Which best describes an algorithm?
- Any calculation done on a computer
- A guess that is usually correct
- A precise step-by-step procedure that solves every problem of a certain kind
- A formula with letters in it
Show answer
Answer: C. An algorithm is a precise sequence of basic steps that solves a whole class of problems, such as adding any two whole numbers. It does not need a computer, and it must give the right answer every time.
-
2. Adding 678 + 459 by the column algorithm, what happens in the first (units) column?
- Write 17
- Write 7, carry 1
- Write 1, carry 7
- Write 7, carry 0
Show answer
Answer: B. Units: 8 + 9 = 17, which is 10 or more, so write the units digit 7 and set carry to 1. The full answer is 1137.
-
3. What is the largest possible carry in column addition of two numbers?
- 1
- 2
- 9
- 10
Show answer
Answer: A. A column can total at most 9 + 9 + 1 = 19. That is less than 20, so at most one ten is carried: the carry is always 0 or 1.
-
4. A student follows the addition algorithm for 586 + 947 but leaves out the last step ('if carry is 1, write 1 on the left'). What does the student get?
- 1533
- 533
- 1433
- 15313
Show answer
Answer: B. The columns give 3, 3 and 5 with a carry of 1 left over at the end. Without the final step the student writes only 533 and loses the thousand. The correct sum is 1533.
-
5. Moving from adding two 3-digit numbers to adding two 6-digit numbers, how does the work of the column method change?
- It becomes 1000 times as much
- It doubles
- It stays exactly the same
- It needs 3 more columns
Show answer
Answer: D. The column method does one column per digit, so going from 3 digits to 6 digits adds 3 columns. Counting dots would take about 1000 times as long, because the numbers are about 1000 times bigger.
Sign in to keep track of the lessons you finish.