Re:Palindrome Day 20200202
by mkagenius on Sunday February 02, 2020 @01:20AM
(#22215479)
Also they contain only two distinct digits, rest mostly have 3 or more different digits.
[ Parent
| on HN ]
Yeah, we won’t get a two-digit universal palindrome for a long time (12-12-2121).
Yes, a YYYY-MM-DD format palindrome date that is also a palindrome in DD-MM-YYYY and MM-DD-YYYY formats cannot have more than two distinct digits.
Let us represent the 8 digits of such a date (in YYYY-MM-DD format) as abcd-ef-gh.
Since abcd-ef-gh (i.e., YYYY-MM-DD format) is a palindrome, we get a = h, b = g, c = f, and d = e.
Since ef-gh-abcd (i.e., MM-DD-YYYY format) is a palindrome, we get a = h, b = g, c = f, and d = e.
Since gh-ef-abcd (i.e., DD-MM-YYYY format) is a palindrome, we get a = f, b = e, c = h, and d = g.
Combining all of these, we get a = c = f = h and b = d = e = g.
Therefore, such a date must be of the format abab-ba-ba, i.e., it may have a maximum of only two distinct digits.