Fence posts and gaps
Posts and gaps, cuts and pieces, pages counted from 12 to 30: why the answer is so often one more or one less than you think.
A fence is 20 m long, with a post every 4 m. How many posts? Many people say 5, but the answer is 6. Puzzles like this are called fence post puzzles, and they hide in many places: trees in a row, cuts in a log, pages in a book, pills taken every half hour, people in a line. In all of them, the answer is very often one more or one less than the first number you think of. This page shows why, and how to get it right every time.
Posts and gaps
Picture a short fence with 3 posts: post, gap, post, gap, post. There are 3 posts but only 2 gaps. Each gap sits between two posts, and the first post has no gap in front of it. So in a straight line with a post at each end, there is always one more post than gaps.
Remember
Posts = gaps + 1
For a straight row with something at both ends. The number of gaps is the length divided by the space between posts.
Example 1
A straight fence is 36 m long. There is a post every 4 m, with one at each end. How many posts are there?
- Gaps: 36 ÷ 4 = 9.
- Posts: 9 + 1 = 10.
- Check with a small case: a fence of 8 m has posts at 0, 4 and 8 m. That is 2 gaps and 3 posts.
Answer: 10 posts
Trees in a row
The same rule works the other way. If you know how many trees there are, the number of gaps is one less. The distance from the first tree to the last is the gaps times the space.
Remember
Gaps = trees − 1, and distance = gaps × space
Example 2
8 trees stand in a straight row, 5 m apart. How far is it from the first tree to the last?
- 8 trees have 8 − 1 = 7 gaps between them.
- Distance: 7 × 5 = 35 m.
Answer: 35 m
Cuts and pieces
Cutting a log is the same kind of puzzle. One cut makes 2 pieces, two cuts make 3 pieces. The cuts are like the posts in between, and the pieces are like the gaps. So the number of cuts is always one less than the number of pieces.
Remember
Cuts = pieces − 1
Example 3
Each cut through a log takes 4 minutes. How long does it take to cut it into 6 pieces?
- 6 pieces need 6 − 1 = 5 cuts.
- Time: 5 × 4 = 20 minutes.
Answer: 20 minutes
Harder puzzles give you the time for some pieces and ask about a different number. First find the time for one cut. Then use it for the new number of cuts.
Example 4
It takes 9 minutes to cut a log into 4 pieces. How long does it take to cut it into 10 pieces?
- 4 pieces need 3 cuts, so one cut takes 9 ÷ 3 = 3 minutes.
- 10 pieces need 9 cuts.
- Time: 9 × 3 = 27 minutes.
Answer: 27 minutes
Strikes, pills and other things in time
Things that happen at moments in time follow the same rule. The moments are the posts, and the waiting times between them are the gaps. A clock that strikes 6 times has 5 gaps between the strikes. If you take 3 pills, one every 30 minutes, you take the first one at minute 0, so only 2 waits of 30 minutes pass: 60 minutes from the first pill to the last, not 90.
Example 5
A clock strikes 4 times at 4 o'clock. From the first strike to the last takes 6 seconds. How long does it take at 10 o'clock?
- 4 strikes have 3 gaps, so each gap is 6 ÷ 3 = 2 seconds.
- 10 strikes have 9 gaps.
- Time: 9 × 2 = 18 seconds.
Answer: 18 seconds
Counting from one number to another
How many pages are there from page 12 to page 30, if you read both of them? Subtracting gives 30 − 12 = 18, but that counts the gaps between the page numbers. The pages are the posts, so add 1. When both ends count, we say the counting is inclusive.
Remember
From first to last, both included: last − first + 1
Example 6
The seats in a row are numbered from 23 to 41. How many seats are in the row?
- 41 − 23 = 18.
- Both seat 23 and seat 41 are in the row, so add 1: 18 + 1 = 19.
- Check with a small case: seats 1 to 3 are 3 seats, and 3 − 1 + 1 = 3.
Answer: 19 seats
People in a line
Line puzzles come in two kinds. In the first, you know how many people stand in front of someone and how many stand behind. Add them, and then add the person too, because that person is not in either count.
In the second, you know a person's place from the front and from the back. Here the person is counted twice, once in each count, so you take 1 away.
| The puzzle says | Method | Example |
|---|---|---|
| 3 in front of Ana, 5 behind her | front + behind + 1 | 3 + 5 + 1 = 9 people |
| Eva is 4th from the front and 6th from the back | front place + back place − 1 | 4 + 6 − 1 = 9 people |
Example 7
In a line, Sam is 7th from the front and 10th from the back. How many people are in the line?
- 7th from the front means 6 people are in front of Sam.
- 10th from the back means 9 people are behind Sam.
- 6 + 9 + 1 = 16, which is the same as 7 + 10 − 1 = 16.
Answer: 16 people
Try it yourself
1.A straight fence is 40 m long, with a post every 8 m and one at each end. How many posts are there?
Show the answer
6
40 ÷ 8 = 5 gaps, and there is one more post than gaps: 6.
2.12 lamp posts stand in a straight row, 10 m apart. How far is it from the first to the last?
Show the answer
110 m
12 lamp posts have 11 gaps, and 11 × 10 = 110 m.
3.Each cut through a ribbon takes 2 minutes. How long does it take to cut it into 9 pieces?
Show the answer
16 minutes
9 pieces need 8 cuts, and 8 × 2 = 16 minutes.
4.A teacher marks tests numbered 18 to 45. How many tests is that?
Show the answer
28
45 − 18 = 27, plus 1 because both ends count: 28.
5.In a line, Lea is 12th from the front and 9th from the back. How many people are in the line?
Show the answer
20
12 + 9 = 21 counts Lea twice, so there are 21 − 1 = 20 people.
6.A clock strikes 3 times at 3 o'clock, and it takes 4 seconds from the first strike to the last. How long does it take at 9 o'clock?
Show the answer
16 seconds
3 strikes have 2 gaps, so each gap is 2 seconds. 9 strikes have 8 gaps: 8 × 2 = 16 seconds.
Ready to test yourself?
Play Logic: 20 seconds per question, and it gets harder as you go.