Teaser 2427: [Birth products]
From The Sunday Times, 29th March 2009 [link]
A mathematics professor asked his students to look at their date of birth (dd/mm/yyyy) and calculate their “birth product”: the product of dd and mm. He asked them to number the days of the year of their birth (1 = 1st Jan;
2 = 2nd Jan; 32 = 1st Feb; and so on) and work out the number of the day of their birth date. One student said that his answers were the same, and that multiplying that number by a smaller whole number gave an answer equal to his birth year. The professor, an older man, said the same was true for him.What (using dd/mm/yyyy) are the student’s and professor’s birth dates?
This puzzle was originally published with no title.
[teaser2427]








Jim Randell 2:20 pm on 26 June 2026 Permalink |
This Python program considers possible birth years between 1900 and 2000.
It factorises the year into candidate values for the “birth product” and the “smaller number”. It then finds the day of the year that corresponds to the candidate “birth product” and verifies that the day × month product gives the same value. If this test succeeds then we have found a date with the required properties.
It runs in 66ms. (Internal runtime is 941µs).
from datetime import (date, timedelta) from enigma import (irange, divisors_pairs, printf) # consider years for y in irange(1900, 2000): # divide year in <smaller number> and <birth product> for (sn, bp) in divisors_pairs(y): if bp > 366 or sn == bp: continue # check day bp in year y d = date(y, 1, 1) + timedelta(days=bp - 1) # does it have the correct product? if not (d.month * d.day == bp and d.year == y): continue # output viable date printf("year {y} = {sn} * {bp}; day {bp} = {d}")Solution: The student’s DOB is: 30/03/1980. The professor’s DOB is: 30/05/1950.
For the student we have:
For the professor we have:
LikeLike
Ruud 6:39 pm on 26 June 2026 Permalink |
import datetime day = datetime.datetime(1900, 1, 1) while day < datetime.datetime(2000, 1, 1): if day.day * day.month == (daynr := (day - datetime.datetime(day.year, 1, 1)).days + 1): multiplier, rest = divmod(day.year, daynr) if rest == 0 and multiplier < daynr: print(f"{day.day}/{day.month}/{day.year}") day += datetime.timedelta(days=1)LikeLike