Hacker News .hnnew | past | comments | ask | show | jobs | submitlogin

Yes. This is the '10 posts, nine spaces' problem.

Here is another version:

A fence is made using 15 posts spaced equally along a straight line. There are 3m between each post. What is the distance between the first and last post?

When I'm teaching this kind of thing, we go out and walk around the building site opposite with a few 15m measuring tapes. The physical walking out and measuring helps.



Surely I can't be the only one who wondered if the posts were of non-negligible thickness!


OK, you got me!

Change "There are 3m between each post." to "The distance from one post centre to the next is 3m"

Which illustrates the general point: you need teams working the test and checking their answers against what the writer thought the answers were. You also need English specialists checking the wording of the questions.


Now - all those "smarter than this schoolteacher" programmers who've never put code with an off-by-one error into production put your hands up.

Yeah, my hand is firmly down too…


So does considering simpler cases of two posts (3), three posts (3 + 3), and four posts (3 + 3 + 3), then discovering the pattern (3(n - 1)).


Yes when teaching GCSE here in the UK where there is an algebra component.

I've also had students in Functional Maths classes just sketching arrangements of posts and counting the spaces.


+1 for arranging your question so that it has The answer.




Consider applying for YC's Fall 2026 batch! Applications are open till July 27.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: