Two creepers spiralling up the same tree
A jasmine and a rose both start from the same point at the base of a tree trunk and climb to the same point on the first branch. The jasmine winds clockwise around the trunk exactly 5 times on the way up; the rose winds anticlockwise exactly 3 times. Both climb steadily.
Not counting the starting point at the bottom or the meeting point at the top, how many times do the two creepers cross?
Show a hint
Unroll the trunk into a flat rectangle. Each creeper becomes a straight line (repeated across the rectangle). Count the heights at which the two lines land on the same point of the circumference.
Your answer
Solving needs a free account
Answers, streaks and solutions unlock when you are signed in. Reading the question and the hint stays free.
Discussion
💡 Discussion rules
- No full solutions here. Hints and approaches only.
- Complexity, edge cases and intuition are the point.
- Interview experiences are welcome. Respect your NDAs.
Loading discussion…
Learn the concepts
The theory behind this question.