"hh:mm", from "00:00" to "23:59". Some of its segments have gone dark, so some digits in the string display are replaced by ?.
In how many ways can each ? be replaced by a digit from 0 to 9 so that the result is a real time of day?display="2?:4?" → 40
The hours can be 20 to 23 (4 options) and the minutes 40 to 49 (10 options): 4 · 10 = 40 in total.
display="?9:?5" → 12
The hours are 09 or 19 (there is no 29) and the minutes 05, 15, …, 55. The answer is 2 · 6 = 12.
display="13:07" → 1
?display="2?:4?"
40
Run checks the first 3 tests in your browser. Submit checks all 106 tests on the server, hidden ones included.