Brain-Teaser 346: Antics
From The Sunday Times, 24th December 1967 [link]
All distances and dimensions are exact feet; all times, exact seconds; all the spiders run at 5 feet per second; and drop with a maximum fall of 30 feet.
Ara and Chne sat hungry in the top north-west corner of the palace corridor (no flies).
“Could be and ant or two in that bottom south-east corner by the garden door”, said Chne.
“True”, said Ara. She dropped to the floor and headed straight for the prospective meal, while Chne (she never drops) instantly set off down the shortest route via the north wall and floor.
Farther along the corridor, Taran and Tula sat hungry together at the top of the south wall.
“Hey, look!”, cried Taran, as the ant-hunters approached.
“Must be something in that corner”, said Tula, dropping to the floor and speeding straight toward it.
Taran at the same moment ran direct for the corner. As she started, Ara, clocking 39 seconds, passed by.
Tangle and wrangle! Dead heat all! No ants!
How wide is the corridor?
This puzzle is included in the book Sunday Times Brain Teasers (1974). The puzzle text is taken from the book.
[teaser346]
Jim Randell 10:09 am on 25 June 2023 Permalink |
By folding the walls of the corridor flat we can turn all of the paths into straight lines in the same plane.
Measuring all distances in feet, and times in “ticks” (= 1/5 second), then each spider travels 1 ft per tick.
We don’t know how long it takes a spider to drop the height of the corridor, but this is calculated as part of the solution.
The following Python program runs in 58ms. (Internal runtime is 859µs).
Run: [ @replit ]
from enigma import (pythagorean_triples, sum_of_squares, is_square, printf) # consider the path Taran takes, it is the hypotenuse of a Pythagorean triple for (a, b, t2) in pythagorean_triples(999): # but must be divisible by 5 if t2 % 5 > 0: continue # and the height of the corridor must be no more than 30 for (h, t1) in [(a, b), (b, a)]: # and Tula's path must also be a multiple of 5 if h > 30 or t1 % 5 > 0: continue # and their times are equal, so we can calculate drop time (in 1/5 s) d = t2 - t1 # total time for Ara and Chne is 195 ticks more than for t2 t = t2 + 195 # and this is Chne's distance, the hypotenuse of a (w + h, l, t) triangle for (x, y) in sum_of_squares(t * t, min_v=1): for (wh, l) in [(x, y), (y, x)]: w = wh - h if w < 0 or not (l > t1): continue # Ara's time is the same as Chne's z = is_square(w * w + l * l) if z is None or z + d != t: continue # output solution printf("h={h} t1={t1} t2={t2}; d={d} t={t}; w={w} l={l} z={z}")Solution: The corridor is 39 ft wide.
And 25 ft high, and 252 ft long.
Chne takes a direct route (across the N wall and floor) so travels hypot(39 + 25, 252) = 260 ft (in 52s).
Ara drops to the floor (which takes 1s) and travels hypot(39, 252) = 255 ft (in 51s).
At the 39s mark Taran and Tula set off on their journeys.
Taran crosses the S wall diagonally for 13s, so travels a distance of 65 ft.
Tula drops to the floor (1s) and travels for 12s a distance of 60 ft.
And so they all arrive in the SE bottom corner at exactly the same time.
LikeLike