Pairs of palindromic anagramic dates separated by a palindromic number of days

8

1

Definitions:

A palindrome is a string which reads the same backward or forward (not counting spaces or special characters), such as "madam" or "Sorel Eros". A date is said to be a palindrome when its dd-mm-yyyy format is a palindrome (or any other local representation).

Two strings are said to be anagrams when the contain the same characters (modulo a rearrangement), such as "Silent" and "Listen". Two dates are anagrams when their representation (the same as the one chosen for 1.) are anagrams.

Challenge:

The challenge is to find all the pairs (a,b) of dates (between 1/1/01 and 12/31/9999) which satisfy the following three conditions :

  1. a and b are different
  2. a and b are palindromes
  3. a and b are anagrams
  4. a and b are separated by a number of days which is a palindrome.

Constraints

You can choose one of the three date formats :

  • yyyy-mm-dd
  • dd-mm-yyyy
  • mm-dd-yyyy

That means left padding with zeros for days and month (02/02/1999) and a 4 zeros padding for years.

You must respect leap years + every 100 years leap + every 400 years leap such as specified in the Proleptic Gregorian calendar

Input None.

Output

Pairs of dates (same format) and the number of days separating them Display format can be different to the computation format.

31-03-3013 - 13-03-3031 :: 6556

[EDIT]

Standard loopholes apply

This is code golf, shortest code wins!

Regis Portalez

Posted 2020-02-27T12:18:20.860

Reputation: 309

4Are single digit numbers palindromes? if they are, we need to list all palindromic dates too. So, are a and b different dates? – Galen Ivanov – 2020-02-27T12:47:03.190

When are the numbers left-padded with zeros and with how many zeroes? – RGS – 2020-02-27T12:53:57.083

1Edited to address comments. Yes a and b are different and the numbers are padded (february -> 02, december -> 12 and same for day) – Regis Portalez – 2020-02-27T13:24:39.837

Haha just checking if both dates are palindromes for the first 50 years times out in TIO for PHP, gonna warm up the max_execution_time in preparation – Kaddath – 2020-02-27T14:03:50.283

1Why having edited for "no zero padding for years"?, it wasn't asked for and will bother many I think.. can we have the choice on this? – Kaddath – 2020-02-27T14:21:01.143

Are we allowed to check the palindromizes for dates with format dd-mm-yyyy, yet still output them as format yyyy-mm-dd? – Kevin Cruijssen – 2020-02-27T14:36:56.403

1@KevinCruijssen yes; Computation must be in the same format system, but output can be any format – Regis Portalez – 2020-02-27T14:58:47.597

Answers

10

Polyglot, 0 bytes

When using the formats yyyy-mm-dd or mm-dd-yyyy, the list of palindrome dates are:

yyyy-mm-dd: [0101-10-10, 0110-01-10, 0111-11-10, 0120-02-10, 0121-12-10, 0130-03-10, 0140-04-10, 0150-05-10, 0160-06-10, 0170-07-10, 0180-08-10, 0190-09-10, 0201-10-20, 0210-01-20, 0211-11-20, 0220-02-20, 0221-12-20, 0230-03-20, 0240-04-20, 0250-05-20, 0260-06-20, 0270-07-20, 0280-08-20, 0290-09-20, 0301-10-30, 0310-01-30, 0311-11-30, 0321-12-30, 0330-03-30, 0340-04-30, 0350-05-30, 0360-06-30, 0370-07-30, 0380-08-30, 0390-09-30, 1001-10-01, 1010-01-01, 1011-11-01, 1020-02-01, 1021-12-01, 1030-03-01, 1040-04-01, 1050-05-01, 1060-06-01, 1070-07-01, 1080-08-01, 1090-09-01, 1101-10-11, 1110-01-11, 1111-11-11, 1120-02-11, 1121-12-11, 1130-03-11, 1140-04-11, 1150-05-11, 1160-06-11, 1170-07-11, 1180-08-11, 1190-09-11, 1201-10-21, 1210-01-21, 1211-11-21, 1220-02-21, 1221-12-21, 1230-03-21, 1240-04-21, 1250-05-21, 1260-06-21, 1270-07-21, 1280-08-21, 1290-09-21, 1301-10-31, 1310-01-31, 1321-12-31, 1330-03-31, 1350-05-31, 1370-07-31, 1380-08-31, 2001-10-02, 2010-01-02, 2011-11-02, 2020-02-02, 2021-12-02, 2030-03-02, 2040-04-02, 2050-05-02, 2060-06-02, 2070-07-02, 2080-08-02, 2090-09-02, 2101-10-12, 2110-01-12, 2111-11-12, 2120-02-12, 2121-12-12, 2130-03-12, 2140-04-12, 2150-05-12, 2160-06-12, 2170-07-12, 2180-08-12, 2190-09-12, 2201-10-22, 2210-01-22, 2211-11-22, 2220-02-22, 2221-12-22, 2230-03-22, 2240-04-22, 2250-05-22, 2260-06-22, 2270-07-22, 2280-08-22, 2290-09-22, 3001-10-03, 3010-01-03, 3011-11-03, 3020-02-03, 3021-12-03, 3030-03-03, 3040-04-03, 3050-05-03, 3060-06-03, 3070-07-03, 3080-08-03, 3090-09-03, 3101-10-13, 3110-01-13, 3111-11-13, 3120-02-13, 3121-12-13, 3130-03-13, 3140-04-13, 3150-05-13, 3160-06-13, 3170-07-13, 3180-08-13, 3190-09-13, 3201-10-23, 3210-01-23, 3211-11-23, 3220-02-23, 3221-12-23, 3230-03-23, 3240-04-23, 3250-05-23, 3260-06-23, 3270-07-23, 3280-08-23, 3290-09-23, 4001-10-04, 4010-01-04, 4011-11-04, 4020-02-04, 4021-12-04, 4030-03-04, 4040-04-04, 4050-05-04, 4060-06-04, 4070-07-04, 4080-08-04, 4090-09-04, 4101-10-14, 4110-01-14, 4111-11-14, 4120-02-14, 4121-12-14, 4130-03-14, 4140-04-14, 4150-05-14, 4160-06-14, 4170-07-14, 4180-08-14, 4190-09-14, 4201-10-24, 4210-01-24, 4211-11-24, 4220-02-24, 4221-12-24, 4230-03-24, 4240-04-24, 4250-05-24, 4260-06-24, 4270-07-24, 4280-08-24, 4290-09-24, 5001-10-05, 5010-01-05, 5011-11-05, 5020-02-05, 5021-12-05, 5030-03-05, 5040-04-05, 5050-05-05, 5060-06-05, 5070-07-05, 5080-08-05, 5090-09-05, 5101-10-15, 5110-01-15, 5111-11-15, 5120-02-15, 5121-12-15, 5130-03-15, 5140-04-15, 5150-05-15, 5160-06-15, 5170-07-15, 5180-08-15, 5190-09-15, 5201-10-25, 5210-01-25, 5211-11-25, 5220-02-25, 5221-12-25, 5230-03-25, 5240-04-25, 5250-05-25, 5260-06-25, 5270-07-25, 5280-08-25, 5290-09-25, 6001-10-06, 6010-01-06, 6011-11-06, 6020-02-06, 6021-12-06, 6030-03-06, 6040-04-06, 6050-05-06, 6060-06-06, 6070-07-06, 6080-08-06, 6090-09-06, 6101-10-16, 6110-01-16, 6111-11-16, 6120-02-16, 6121-12-16, 6130-03-16, 6140-04-16, 6150-05-16, 6160-06-16, 6170-07-16, 6180-08-16, 6190-09-16, 6201-10-26, 6210-01-26, 6211-11-26, 6220-02-26, 6221-12-26, 6230-03-26, 6240-04-26, 6250-05-26, 6260-06-26, 6270-07-26, 6280-08-26, 6290-09-26, 7001-10-07, 7010-01-07, 7011-11-07, 7020-02-07, 7021-12-07, 7030-03-07, 7040-04-07, 7050-05-07, 7060-06-07, 7070-07-07, 7080-08-07, 7090-09-07, 7101-10-17, 7110-01-17, 7111-11-17, 7120-02-17, 7121-12-17, 7130-03-17, 7140-04-17, 7150-05-17, 7160-06-17, 7170-07-17, 7180-08-17, 7190-09-17, 7201-10-27, 7210-01-27, 7211-11-27, 7220-02-27, 7221-12-27, 7230-03-27, 7240-04-27, 7250-05-27, 7260-06-27, 7270-07-27, 7280-08-27, 7290-09-27, 8001-10-08, 8010-01-08, 8011-11-08, 8020-02-08, 8021-12-08, 8030-03-08, 8040-04-08, 8050-05-08, 8060-06-08, 8070-07-08, 8080-08-08, 8090-09-08, 8101-10-18, 8110-01-18, 8111-11-18, 8120-02-18, 8121-12-18, 8130-03-18, 8140-04-18, 8150-05-18, 8160-06-18, 8170-07-18, 8180-08-18, 8190-09-18, 8201-10-28, 8210-01-28, 8211-11-28, 8220-02-28, 8221-12-28, 8230-03-28, 8240-04-28, 8250-05-28, 8260-06-28, 8270-07-28, 8280-08-28, 8290-09-28, 9001-10-09, 9010-01-09, 9011-11-09, 9020-02-09, 9021-12-09, 9030-03-09, 9040-04-09, 9050-05-09, 9060-06-09, 9070-07-09, 9080-08-09, 9090-09-09, 9101-10-19, 9110-01-19, 9111-11-19, 9120-02-19, 9121-12-19, 9130-03-19, 9140-04-19, 9150-05-19, 9160-06-19, 9170-07-19, 9180-08-19, 9190-09-19, 9201-10-29, 9210-01-29, 9211-11-29, 9220-02-29, 9221-12-29, 9230-03-29, 9240-04-29, 9250-05-29, 9260-06-29, 9270-07-29, 9280-08-29, 9290-09-29]
mm-dd-yyyy: [10-10-0101, 01-10-0110, 11-10-0111, 02-10-0120, 12-10-0121, 03-10-0130, 04-10-0140, 05-10-0150, 06-10-0160, 07-10-0170, 08-10-0180, 09-10-0190, 10-20-0201, 01-20-0210, 11-20-0211, 02-20-0220, 12-20-0221, 03-20-0230, 04-20-0240, 05-20-0250, 06-20-0260, 07-20-0270, 08-20-0280, 09-20-0290, 10-30-0301, 01-30-0310, 11-30-0311, 12-30-0321, 03-30-0330, 04-30-0340, 05-30-0350, 06-30-0360, 07-30-0370, 08-30-0380, 09-30-0390, 10-01-1001, 01-01-1010, 11-01-1011, 02-01-1020, 12-01-1021, 03-01-1030, 04-01-1040, 05-01-1050, 06-01-1060, 07-01-1070, 08-01-1080, 09-01-1090, 10-11-1101, 01-11-1110, 11-11-1111, 02-11-1120, 12-11-1121, 03-11-1130, 04-11-1140, 05-11-1150, 06-11-1160, 07-11-1170, 08-11-1180, 09-11-1190, 10-21-1201, 01-21-1210, 11-21-1211, 02-21-1220, 12-21-1221, 03-21-1230, 04-21-1240, 05-21-1250, 06-21-1260, 07-21-1270, 08-21-1280, 09-21-1290, 10-31-1301, 01-31-1310, 12-31-1321, 03-31-1330, 05-31-1350, 07-31-1370, 08-31-1380, 10-02-2001, 01-02-2010, 11-02-2011, 02-02-2020, 12-02-2021, 03-02-2030, 04-02-2040, 05-02-2050, 06-02-2060, 07-02-2070, 08-02-2080, 09-02-2090, 10-12-2101, 01-12-2110, 11-12-2111, 02-12-2120, 12-12-2121, 03-12-2130, 04-12-2140, 05-12-2150, 06-12-2160, 07-12-2170, 08-12-2180, 09-12-2190, 10-22-2201, 01-22-2210, 11-22-2211, 02-22-2220, 12-22-2221, 03-22-2230, 04-22-2240, 05-22-2250, 06-22-2260, 07-22-2270, 08-22-2280, 09-22-2290, 10-03-3001, 01-03-3010, 11-03-3011, 02-03-3020, 12-03-3021, 03-03-3030, 04-03-3040, 05-03-3050, 06-03-3060, 07-03-3070, 08-03-3080, 09-03-3090, 10-13-3101, 01-13-3110, 11-13-3111, 02-13-3120, 12-13-3121, 03-13-3130, 04-13-3140, 05-13-3150, 06-13-3160, 07-13-3170, 08-13-3180, 09-13-3190, 10-23-3201, 01-23-3210, 11-23-3211, 02-23-3220, 12-23-3221, 03-23-3230, 04-23-3240, 05-23-3250, 06-23-3260, 07-23-3270, 08-23-3280, 09-23-3290, 10-04-4001, 01-04-4010, 11-04-4011, 02-04-4020, 12-04-4021, 03-04-4030, 04-04-4040, 05-04-4050, 06-04-4060, 07-04-4070, 08-04-4080, 09-04-4090, 10-14-4101, 01-14-4110, 11-14-4111, 02-14-4120, 12-14-4121, 03-14-4130, 04-14-4140, 05-14-4150, 06-14-4160, 07-14-4170, 08-14-4180, 09-14-4190, 10-24-4201, 01-24-4210, 11-24-4211, 02-24-4220, 12-24-4221, 03-24-4230, 04-24-4240, 05-24-4250, 06-24-4260, 07-24-4270, 08-24-4280, 09-24-4290, 10-05-5001, 01-05-5010, 11-05-5011, 02-05-5020, 12-05-5021, 03-05-5030, 04-05-5040, 05-05-5050, 06-05-5060, 07-05-5070, 08-05-5080, 09-05-5090, 10-15-5101, 01-15-5110, 11-15-5111, 02-15-5120, 12-15-5121, 03-15-5130, 04-15-5140, 05-15-5150, 06-15-5160, 07-15-5170, 08-15-5180, 09-15-5190, 10-25-5201, 01-25-5210, 11-25-5211, 02-25-5220, 12-25-5221, 03-25-5230, 04-25-5240, 05-25-5250, 06-25-5260, 07-25-5270, 08-25-5280, 09-25-5290, 10-06-6001, 01-06-6010, 11-06-6011, 02-06-6020, 12-06-6021, 03-06-6030, 04-06-6040, 05-06-6050, 06-06-6060, 07-06-6070, 08-06-6080, 09-06-6090, 10-16-6101, 01-16-6110, 11-16-6111, 02-16-6120, 12-16-6121, 03-16-6130, 04-16-6140, 05-16-6150, 06-16-6160, 07-16-6170, 08-16-6180, 09-16-6190, 10-26-6201, 01-26-6210, 11-26-6211, 02-26-6220, 12-26-6221, 03-26-6230, 04-26-6240, 05-26-6250, 06-26-6260, 07-26-6270, 08-26-6280, 09-26-6290, 10-07-7001, 01-07-7010, 11-07-7011, 02-07-7020, 12-07-7021, 03-07-7030, 04-07-7040, 05-07-7050, 06-07-7060, 07-07-7070, 08-07-7080, 09-07-7090, 10-17-7101, 01-17-7110, 11-17-7111, 02-17-7120, 12-17-7121, 03-17-7130, 04-17-7140, 05-17-7150, 06-17-7160, 07-17-7170, 08-17-7180, 09-17-7190, 10-27-7201, 01-27-7210, 11-27-7211, 02-27-7220, 12-27-7221, 03-27-7230, 04-27-7240, 05-27-7250, 06-27-7260, 07-27-7270, 08-27-7280, 09-27-7290, 10-08-8001, 01-08-8010, 11-08-8011, 02-08-8020, 12-08-8021, 03-08-8030, 04-08-8040, 05-08-8050, 06-08-8060, 07-08-8070, 08-08-8080, 09-08-8090, 10-18-8101, 01-18-8110, 11-18-8111, 02-18-8120, 12-18-8121, 03-18-8130, 04-18-8140, 05-18-8150, 06-18-8160, 07-18-8170, 08-18-8180, 09-18-8190, 10-28-8201, 01-28-8210, 11-28-8211, 02-28-8220, 12-28-8221, 03-28-8230, 04-28-8240, 05-28-8250, 06-28-8260, 07-28-8270, 08-28-8280, 09-28-8290, 10-09-9001, 01-09-9010, 11-09-9011, 02-09-9020, 12-09-9021, 03-09-9030, 04-09-9040, 05-09-9050, 06-09-9060, 07-09-9070, 08-09-9080, 09-09-9090, 10-19-9101, 01-19-9110, 11-19-9111, 02-19-9120, 12-19-9121, 03-19-9130, 04-19-9140, 05-19-9150, 06-19-9160, 07-19-9170, 08-19-9180, 09-19-9190, 10-29-9201, 01-29-9210, 11-29-9211, 02-29-9220, 12-29-9221, 03-29-9230, 04-29-9240, 05-29-9250, 06-29-9260, 07-29-9270, 08-29-9280, 09-29-9290]

All possible date-pairs which are anagrams between one-another are:

yyyy-mm-dd: [[0101-10-10,0110-10-01], [0101-10-10,1001-01-10], [0101-10-10,1010-01-01], [0102-10-20,0120-10-02], [0102-10-20,1002-01-20], [0102-10-20,1020-01-02], [0102-10-20,2001-02-10], [0102-10-20,2010-02-01], [0103-10-30,0130-10-03], [0103-10-30,1003-01-30], [0103-10-30,1030-01-03], [0103-10-30,3001-03-10], [0103-10-30,3010-03-01], [0110-10-01,1001-01-10], [0110-10-01,1010-01-01], [0111-10-11,1011-01-11], [0111-10-11,1101-11-10], [0111-10-11,1110-11-01], [0112-10-21,0121-10-12], [0112-10-21,1012-01-21], [0112-10-21,1021-01-12], [0112-10-21,1102-11-20], [0112-10-21,1120-11-02], [0112-10-21,2011-02-11], [0112-10-21,2101-12-10], [0112-10-21,2110-12-01], [0113-10-31,0131-10-13], [0113-10-31,1013-01-31], [0113-10-31,1031-01-13], [0113-10-31,1103-11-30], [0113-10-31,1130-11-03], [0113-10-31,3011-03-11], [0120-10-02,1002-01-20], [0120-10-02,1020-01-02], [0120-10-02,2001-02-10], [0120-10-02,2010-02-01], [0121-10-12,1012-01-21], [0121-10-12,1021-01-12], [0121-10-12,1102-11-20], [0121-10-12,1120-11-02], [0121-10-12,2011-02-11], [0121-10-12,2101-12-10], [0121-10-12,2110-12-01], [0122-10-22,1022-01-22], [0122-10-22,2012-02-21], [0122-10-22,2021-02-12], [0122-10-22,2102-12-20], [0122-10-22,2120-12-02], [0130-10-03,1003-01-30], [0130-10-03,1030-01-03], [0130-10-03,3001-03-10], [0130-10-03,3010-03-01], [0131-10-13,1013-01-31], [0131-10-13,1031-01-13], [0131-10-13,1103-11-30], [0131-10-13,1130-11-03], [0131-10-13,3011-03-11], [0132-10-23,1032-01-23], [0132-10-23,2031-02-13], [0132-10-23,2103-12-30], [0132-10-23,2130-12-03], [0132-10-23,3012-03-21], [0132-10-23,3021-03-12], [0140-10-04,1040-01-04], [0140-10-04,4001-04-10], [0140-10-04,4010-04-01], [0141-10-14,1041-01-14], [0141-10-14,1140-11-04], [0141-10-14,4011-04-11], [0142-10-24,1042-01-24], [0142-10-24,2041-02-14], [0142-10-24,2140-12-04], [0142-10-24,4012-04-21], [0142-10-24,4021-04-12], [0150-10-05,1050-01-05], [0150-10-05,5001-05-10], [0150-10-05,5010-05-01], [0151-10-15,1051-01-15], [0151-10-15,1150-11-05], [0151-10-15,5011-05-11], [0152-10-25,1052-01-25], [0152-10-25,2051-02-15], [0152-10-25,2150-12-05], [0152-10-25,5012-05-21], [0152-10-25,5021-05-12], [0160-10-06,1060-01-06], [0160-10-06,6001-06-10], [0160-10-06,6010-06-01], [0161-10-16,1061-01-16], [0161-10-16,1160-11-06], [0161-10-16,6011-06-11], [0162-10-26,1062-01-26], [0162-10-26,2061-02-16], [0162-10-26,2160-12-06], [0162-10-26,6012-06-21], [0162-10-26,6021-06-12], [0170-10-07,1070-01-07], [0170-10-07,7001-07-10], [0170-10-07,7010-07-01], [0171-10-17,1071-01-17], [0171-10-17,1170-11-07], [0171-10-17,7011-07-11], [0172-10-27,1072-01-27], [0172-10-27,2071-02-17], [0172-10-27,2170-12-07], [0172-10-27,7012-07-21], [0172-10-27,7021-07-12], [0180-10-08,1080-01-08], [0180-10-08,8001-08-10], [0180-10-08,8010-08-01], [0181-10-18,1081-01-18], [0181-10-18,1180-11-08], [0181-10-18,8011-08-11], [0182-10-28,1082-01-28], [0182-10-28,2081-02-18], [0182-10-28,2180-12-08], [0182-10-28,8012-08-21], [0182-10-28,8021-08-12], [0190-10-09,1090-01-09], [0190-10-09,9001-09-10], [0190-10-09,9010-09-01], [0191-10-19,1091-01-19], [0191-10-19,1190-11-09], [0191-10-19,9011-09-11], [0192-10-29,1092-01-29], [0192-10-29,2091-02-19], [0192-10-29,2190-12-09], [0192-10-29,9012-09-21], [0192-10-29,9021-09-12], [1001-01-10,1010-01-01], [1002-01-20,1020-01-02], [1002-01-20,2001-02-10], [1002-01-20,2010-02-01], [1003-01-30,1030-01-03], [1003-01-30,3001-03-10], [1003-01-30,3010-03-01], [1011-01-11,1101-11-10], [1011-01-11,1110-11-01], [1012-01-21,1021-01-12], [1012-01-21,1102-11-20], [1012-01-21,1120-11-02], [1012-01-21,2011-02-11], [1012-01-21,2101-12-10], [1012-01-21,2110-12-01], [1013-01-31,1031-01-13], [1013-01-31,1103-11-30], [1013-01-31,1130-11-03], [1013-01-31,3011-03-11], [1020-01-02,2001-02-10], [1020-01-02,2010-02-01], [1021-01-12,1102-11-20], [1021-01-12,1120-11-02], [1021-01-12,2011-02-11], [1021-01-12,2101-12-10], [1021-01-12,2110-12-01], [1022-01-22,2012-02-21], [1022-01-22,2021-02-12], [1022-01-22,2102-12-20], [1022-01-22,2120-12-02], [1030-01-03,3001-03-10], [1030-01-03,3010-03-01], [1031-01-13,1103-11-30], [1031-01-13,1130-11-03], [1031-01-13,3011-03-11], [1032-01-23,2031-02-13], [1032-01-23,2103-12-30], [1032-01-23,2130-12-03], [1032-01-23,3012-03-21], [1032-01-23,3021-03-12], [1040-01-04,4001-04-10], [1040-01-04,4010-04-01], [1041-01-14,1140-11-04], [1041-01-14,4011-04-11], [1042-01-24,2041-02-14], [1042-01-24,2140-12-04], [1042-01-24,4012-04-21], [1042-01-24,4021-04-12], [1050-01-05,5001-05-10], [1050-01-05,5010-05-01], [1051-01-15,1150-11-05], [1051-01-15,5011-05-11], [1052-01-25,2051-02-15], [1052-01-25,2150-12-05], [1052-01-25,5012-05-21], [1052-01-25,5021-05-12], [1060-01-06,6001-06-10], [1060-01-06,6010-06-01], [1061-01-16,1160-11-06], [1061-01-16,6011-06-11], [1062-01-26,2061-02-16], [1062-01-26,2160-12-06], [1062-01-26,6012-06-21], [1062-01-26,6021-06-12], [1070-01-07,7001-07-10], [1070-01-07,7010-07-01], [1071-01-17,1170-11-07], [1071-01-17,7011-07-11], [1072-01-27,2071-02-17], [1072-01-27,2170-12-07], [1072-01-27,7012-07-21], [1072-01-27,7021-07-12], [1080-01-08,8001-08-10], [1080-01-08,8010-08-01], [1081-01-18,1180-11-08], [1081-01-18,8011-08-11], [1082-01-28,2081-02-18], [1082-01-28,2180-12-08], [1082-01-28,8012-08-21], [1082-01-28,8021-08-12], [1090-01-09,9001-09-10], [1090-01-09,9010-09-01], [1091-01-19,1190-11-09], [1091-01-19,9011-09-11], [1092-01-29,2091-02-19], [1092-01-29,2190-12-09], [1092-01-29,9012-09-21], [1092-01-29,9021-09-12], [1101-11-10,1110-11-01], [1102-11-20,1120-11-02], [1102-11-20,2011-02-11], [1102-11-20,2101-12-10], [1102-11-20,2110-12-01], [1103-11-30,1130-11-03], [1103-11-30,3011-03-11], [1112-11-21,1121-11-12], [1112-11-21,2111-12-11], [1120-11-02,2011-02-11], [1120-11-02,2101-12-10], [1120-11-02,2110-12-01], [1121-11-12,2111-12-11], [1122-11-22,2112-12-21], [1122-11-22,2121-12-12], [1130-11-03,3011-03-11], [1132-11-23,2113-12-31], [1132-11-23,2131-12-13], [1140-11-04,4011-04-11], [1142-11-24,2141-12-14], [1150-11-05,5011-05-11], [1152-11-25,2151-12-15], [1160-11-06,6011-06-11], [1162-11-26,2161-12-16], [1170-11-07,7011-07-11], [1172-11-27,2171-12-17], [1180-11-08,8011-08-11], [1182-11-28,2181-12-18], [1190-11-09,9011-09-11], [1192-11-29,2191-12-19], [2001-02-10,2010-02-01], [2002-02-20,2020-02-02], [2011-02-11,2101-12-10], [2011-02-11,2110-12-01], [2012-02-21,2021-02-12], [2012-02-21,2102-12-20], [2012-02-21,2120-12-02], [2021-02-12,2102-12-20], [2021-02-12,2120-12-02], [2030-02-03,3002-03-20], [2030-02-03,3020-03-02], [2031-02-13,2103-12-30], [2031-02-13,2130-12-03], [2031-02-13,3012-03-21], [2031-02-13,3021-03-12], [2032-02-23,3022-03-22], [2040-02-04,4002-04-20], [2040-02-04,4020-04-02], [2041-02-14,2140-12-04], [2041-02-14,4012-04-21], [2041-02-14,4021-04-12], [2042-02-24,4022-04-22], [2050-02-05,5002-05-20], [2050-02-05,5020-05-02], [2051-02-15,2150-12-05], [2051-02-15,5012-05-21], [2051-02-15,5021-05-12], [2052-02-25,5022-05-22], [2060-02-06,6002-06-20], [2060-02-06,6020-06-02], [2061-02-16,2160-12-06], [2061-02-16,6012-06-21], [2061-02-16,6021-06-12], [2062-02-26,6022-06-22], [2070-02-07,7002-07-20], [2070-02-07,7020-07-02], [2071-02-17,2170-12-07], [2071-02-17,7012-07-21], [2071-02-17,7021-07-12], [2072-02-27,7022-07-22], [2080-02-08,8002-08-20], [2080-02-08,8020-08-02], [2081-02-18,2180-12-08], [2081-02-18,8012-08-21], [2081-02-18,8021-08-12], [2082-02-28,8022-08-22], [2090-02-09,9002-09-20], [2090-02-09,9020-09-02], [2091-02-19,2190-12-09], [2091-02-19,9012-09-21], [2091-02-19,9021-09-12], [2092-02-29,9022-09-22], [2101-12-10,2110-12-01], [2102-12-20,2120-12-02], [2103-12-30,2130-12-03], [2103-12-30,3012-03-21], [2103-12-30,3021-03-12], [2112-12-21,2121-12-12], [2113-12-31,2131-12-13], [2130-12-03,3012-03-21], [2130-12-03,3021-03-12], [2140-12-04,4012-04-21], [2140-12-04,4021-04-12], [2150-12-05,5012-05-21], [2150-12-05,5021-05-12], [2160-12-06,6012-06-21], [2160-12-06,6021-06-12], [2170-12-07,7012-07-21], [2170-12-07,7021-07-12], [2180-12-08,8012-08-21], [2180-12-08,8021-08-12], [2190-12-09,9012-09-21], [2190-12-09,9021-09-12], [3001-03-10,3010-03-01], [3002-03-20,3020-03-02], [3003-03-30,3030-03-03], [3012-03-21,3021-03-12], [3013-03-31,3031-03-13], [3040-03-04,4003-04-30], [3040-03-04,4030-04-03], [3041-03-14,4031-04-13], [3042-03-24,4032-04-23], [3050-03-05,5003-05-30], [3050-03-05,5030-05-03], [3051-03-15,5013-05-31], [3051-03-15,5031-05-13], [3052-03-25,5032-05-23], [3060-03-06,6003-06-30], [3060-03-06,6030-06-03], [3061-03-16,6031-06-13], [3062-03-26,6032-06-23], [3070-03-07,7003-07-30], [3070-03-07,7030-07-03], [3071-03-17,7013-07-31], [3071-03-17,7031-07-13], [3072-03-27,7032-07-23], [3080-03-08,8003-08-30], [3080-03-08,8030-08-03], [3081-03-18,8013-08-31], [3081-03-18,8031-08-13], [3082-03-28,8032-08-23], [3090-03-09,9003-09-30], [3090-03-09,9030-09-03], [3091-03-19,9031-09-13], [3092-03-29,9032-09-23], [4001-04-10,4010-04-01], [4002-04-20,4020-04-02], [4003-04-30,4030-04-03], [4012-04-21,4021-04-12], [4050-04-05,5040-05-04], [4051-04-15,5041-05-14], [4052-04-25,5042-05-24], [4060-04-06,6040-06-04], [4061-04-16,6041-06-14], [4062-04-26,6042-06-24], [4070-04-07,7040-07-04], [4071-04-17,7041-07-14], [4072-04-27,7042-07-24], [4080-04-08,8040-08-04], [4081-04-18,8041-08-14], [4082-04-28,8042-08-24], [4090-04-09,9040-09-04], [4091-04-19,9041-09-14], [4092-04-29,9042-09-24], [5001-05-10,5010-05-01], [5002-05-20,5020-05-02], [5003-05-30,5030-05-03], [5012-05-21,5021-05-12], [5013-05-31,5031-05-13], [5060-05-06,6050-06-05], [5061-05-16,6051-06-15], [5062-05-26,6052-06-25], [5070-05-07,7050-07-05], [5071-05-17,7051-07-15], [5072-05-27,7052-07-25], [5080-05-08,8050-08-05], [5081-05-18,8051-08-15], [5082-05-28,8052-08-25], [5090-05-09,9050-09-05], [5091-05-19,9051-09-15], [5092-05-29,9052-09-25], [6001-06-10,6010-06-01], [6002-06-20,6020-06-02], [6003-06-30,6030-06-03], [6012-06-21,6021-06-12], [6070-06-07,7060-07-06], [6071-06-17,7061-07-16], [6072-06-27,7062-07-26], [6080-06-08,8060-08-06], [6081-06-18,8061-08-16], [6082-06-28,8062-08-26], [6090-06-09,9060-09-06], [6091-06-19,9061-09-16], [6092-06-29,9062-09-26], [7001-07-10,7010-07-01], [7002-07-20,7020-07-02], [7003-07-30,7030-07-03], [7012-07-21,7021-07-12], [7013-07-31,7031-07-13], [7080-07-08,8070-08-07], [7081-07-18,8071-08-17], [7082-07-28,8072-08-27], [7090-07-09,9070-09-07], [7091-07-19,9071-09-17], [7092-07-29,9072-09-27], [8001-08-10,8010-08-01], [8002-08-20,8020-08-02], [8003-08-30,8030-08-03], [8012-08-21,8021-08-12], [8013-08-31,8031-08-13], [8090-08-09,9080-09-08], [8091-08-19,9081-09-18], [8092-08-29,9082-09-28], [9001-09-10,9010-09-01], [9002-09-20,9020-09-02], [9003-09-30,9030-09-03], [9012-09-21,9021-09-12]]
mm-dd-yyyy: [[10-10-0101,01-10-0110], [10-10-0101,10-01-1001], [10-10-0101,01-01-1010], [01-10-0110,10-01-1001], [01-10-0110,01-01-1010], [11-10-0111,11-01-1011], [11-10-0111,10-11-1101], [11-10-0111,01-11-1110], [02-10-0120,10-20-0201], [02-10-0120,01-20-0210], [02-10-0120,02-01-1020], [02-10-0120,10-02-2001], [02-10-0120,01-02-2010], [12-10-0121,11-20-0211], [12-10-0121,12-01-1021], [12-10-0121,02-11-1120], [12-10-0121,10-21-1201], [12-10-0121,01-21-1210], [12-10-0121,11-02-2011], [12-10-0121,10-12-2101], [12-10-0121,01-12-2110], [03-10-0130,10-30-0301], [03-10-0130,01-30-0310], [03-10-0130,03-01-1030], [03-10-0130,10-03-3001], [03-10-0130,01-03-3010], [04-10-0140,04-01-1040], [04-10-0140,10-04-4001], [04-10-0140,01-04-4010], [05-10-0150,05-01-1050], [05-10-0150,10-05-5001], [05-10-0150,01-05-5010], [06-10-0160,06-01-1060], [06-10-0160,10-06-6001], [06-10-0160,01-06-6010], [07-10-0170,07-01-1070], [07-10-0170,10-07-7001], [07-10-0170,01-07-7010], [08-10-0180,08-01-1080], [08-10-0180,10-08-8001], [08-10-0180,01-08-8010], [09-10-0190,09-01-1090], [09-10-0190,10-09-9001], [09-10-0190,01-09-9010], [10-20-0201,01-20-0210], [10-20-0201,02-01-1020], [10-20-0201,10-02-2001], [10-20-0201,01-02-2010], [01-20-0210,02-01-1020], [01-20-0210,10-02-2001], [01-20-0210,01-02-2010], [11-20-0211,12-01-1021], [11-20-0211,02-11-1120], [11-20-0211,10-21-1201], [11-20-0211,01-21-1210], [11-20-0211,11-02-2011], [11-20-0211,10-12-2101], [11-20-0211,01-12-2110], [02-20-0220,02-02-2020], [12-20-0221,02-21-1220], [12-20-0221,12-02-2021], [12-20-0221,02-12-2120], [12-20-0221,10-22-2201], [12-20-0221,01-22-2210], [03-20-0230,03-02-2030], [03-20-0230,02-03-3020], [04-20-0240,04-02-2040], [04-20-0240,02-04-4020], [05-20-0250,05-02-2050], [05-20-0250,02-05-5020], [06-20-0260,06-02-2060], [06-20-0260,02-06-6020], [07-20-0270,07-02-2070], [07-20-0270,02-07-7020], [08-20-0280,08-02-2080], [08-20-0280,02-08-8020], [09-20-0290,09-02-2090], [09-20-0290,02-09-9020], [10-30-0301,01-30-0310], [10-30-0301,03-01-1030], [10-30-0301,10-03-3001], [10-30-0301,01-03-3010], [01-30-0310,03-01-1030], [01-30-0310,10-03-3001], [01-30-0310,01-03-3010], [11-30-0311,03-11-1130], [11-30-0311,10-31-1301], [11-30-0311,01-31-1310], [11-30-0311,11-03-3011], [11-30-0311,10-13-3101], [11-30-0311,01-13-3110], [12-30-0321,03-21-1230], [12-30-0321,03-12-2130], [12-30-0321,12-03-3021], [12-30-0321,02-13-3120], [12-30-0321,10-23-3201], [12-30-0321,01-23-3210], [03-30-0330,03-03-3030], [04-30-0340,04-03-3040], [04-30-0340,03-04-4030], [05-30-0350,05-03-3050], [05-30-0350,03-05-5030], [06-30-0360,06-03-3060], [06-30-0360,03-06-6030], [07-30-0370,07-03-3070], [07-30-0370,03-07-7030], [08-30-0380,08-03-3080], [08-30-0380,03-08-8030], [09-30-0390,09-03-3090], [09-30-0390,03-09-9030], [10-01-1001,01-01-1010], [11-01-1011,10-11-1101], [11-01-1011,01-11-1110], [02-01-1020,10-02-2001], [02-01-1020,01-02-2010], [12-01-1021,02-11-1120], [12-01-1021,10-21-1201], [12-01-1021,01-21-1210], [12-01-1021,11-02-2011], [12-01-1021,10-12-2101], [12-01-1021,01-12-2110], [03-01-1030,10-03-3001], [03-01-1030,01-03-3010], [04-01-1040,10-04-4001], [04-01-1040,01-04-4010], [05-01-1050,10-05-5001], [05-01-1050,01-05-5010], [06-01-1060,10-06-6001], [06-01-1060,01-06-6010], [07-01-1070,10-07-7001], [07-01-1070,01-07-7010], [08-01-1080,10-08-8001], [08-01-1080,01-08-8010], [09-01-1090,10-09-9001], [09-01-1090,01-09-9010], [10-11-1101,01-11-1110], [02-11-1120,10-21-1201], [02-11-1120,01-21-1210], [02-11-1120,11-02-2011], [02-11-1120,10-12-2101], [02-11-1120,01-12-2110], [12-11-1121,11-21-1211], [12-11-1121,11-12-2111], [03-11-1130,10-31-1301], [03-11-1130,01-31-1310], [03-11-1130,11-03-3011], [03-11-1130,10-13-3101], [03-11-1130,01-13-3110], [04-11-1140,11-04-4011], [04-11-1140,10-14-4101], [04-11-1140,01-14-4110], [05-11-1150,11-05-5011], [05-11-1150,10-15-5101], [05-11-1150,01-15-5110], [06-11-1160,11-06-6011], [06-11-1160,10-16-6101], [06-11-1160,01-16-6110], [07-11-1170,11-07-7011], [07-11-1170,10-17-7101], [07-11-1170,01-17-7110], [08-11-1180,11-08-8011], [08-11-1180,10-18-8101], [08-11-1180,01-18-8110], [09-11-1190,11-09-9011], [09-11-1190,10-19-9101], [09-11-1190,01-19-9110], [10-21-1201,01-21-1210], [10-21-1201,11-02-2011], [10-21-1201,10-12-2101], [10-21-1201,01-12-2110], [01-21-1210,11-02-2011], [01-21-1210,10-12-2101], [01-21-1210,01-12-2110], [11-21-1211,11-12-2111], [02-21-1220,12-02-2021], [02-21-1220,02-12-2120], [02-21-1220,10-22-2201], [02-21-1220,01-22-2210], [12-21-1221,12-12-2121], [12-21-1221,11-22-2211], [03-21-1230,03-12-2130], [03-21-1230,12-03-3021], [03-21-1230,02-13-3120], [03-21-1230,10-23-3201], [03-21-1230,01-23-3210], [04-21-1240,04-12-2140], [04-21-1240,12-04-4021], [04-21-1240,02-14-4120], [04-21-1240,10-24-4201], [04-21-1240,01-24-4210], [05-21-1250,05-12-2150], [05-21-1250,12-05-5021], [05-21-1250,02-15-5120], [05-21-1250,10-25-5201], [05-21-1250,01-25-5210], [06-21-1260,06-12-2160], [06-21-1260,12-06-6021], [06-21-1260,02-16-6120], [06-21-1260,10-26-6201], [06-21-1260,01-26-6210], [07-21-1270,07-12-2170], [07-21-1270,12-07-7021], [07-21-1270,02-17-7120], [07-21-1270,10-27-7201], [07-21-1270,01-27-7210], [08-21-1280,08-12-2180], [08-21-1280,12-08-8021], [08-21-1280,02-18-8120], [08-21-1280,10-28-8201], [08-21-1280,01-28-8210], [09-21-1290,09-12-2190], [09-21-1290,12-09-9021], [09-21-1290,02-19-9120], [09-21-1290,10-29-9201], [09-21-1290,01-29-9210], [10-31-1301,01-31-1310], [10-31-1301,11-03-3011], [10-31-1301,10-13-3101], [10-31-1301,01-13-3110], [01-31-1310,11-03-3011], [01-31-1310,10-13-3101], [01-31-1310,01-13-3110], [12-31-1321,12-13-3121], [12-31-1321,11-23-3211], [03-31-1330,03-13-3130], [05-31-1350,05-13-3150], [05-31-1350,03-15-5130], [07-31-1370,07-13-3170], [07-31-1370,03-17-7130], [08-31-1380,08-13-3180], [08-31-1380,03-18-8130], [10-02-2001,01-02-2010], [11-02-2011,10-12-2101], [11-02-2011,01-12-2110], [12-02-2021,02-12-2120], [12-02-2021,10-22-2201], [12-02-2021,01-22-2210], [03-02-2030,02-03-3020], [04-02-2040,02-04-4020], [05-02-2050,02-05-5020], [06-02-2060,02-06-6020], [07-02-2070,02-07-7020], [08-02-2080,02-08-8020], [09-02-2090,02-09-9020], [10-12-2101,01-12-2110], [02-12-2120,10-22-2201], [02-12-2120,01-22-2210], [12-12-2121,11-22-2211], [03-12-2130,12-03-3021], [03-12-2130,02-13-3120], [03-12-2130,10-23-3201], [03-12-2130,01-23-3210], [04-12-2140,12-04-4021], [04-12-2140,02-14-4120], [04-12-2140,10-24-4201], [04-12-2140,01-24-4210], [05-12-2150,12-05-5021], [05-12-2150,02-15-5120], [05-12-2150,10-25-5201], [05-12-2150,01-25-5210], [06-12-2160,12-06-6021], [06-12-2160,02-16-6120], [06-12-2160,10-26-6201], [06-12-2160,01-26-6210], [07-12-2170,12-07-7021], [07-12-2170,02-17-7120], [07-12-2170,10-27-7201], [07-12-2170,01-27-7210], [08-12-2180,12-08-8021], [08-12-2180,02-18-8120], [08-12-2180,10-28-8201], [08-12-2180,01-28-8210], [09-12-2190,12-09-9021], [09-12-2190,02-19-9120], [09-12-2190,10-29-9201], [09-12-2190,01-29-9210], [10-22-2201,01-22-2210], [03-22-2230,02-23-3220], [04-22-2240,02-24-4220], [05-22-2250,02-25-5220], [06-22-2260,02-26-6220], [07-22-2270,02-27-7220], [08-22-2280,02-28-8220], [09-22-2290,02-29-9220], [10-03-3001,01-03-3010], [11-03-3011,10-13-3101], [11-03-3011,01-13-3110], [12-03-3021,02-13-3120], [12-03-3021,10-23-3201], [12-03-3021,01-23-3210], [04-03-3040,03-04-4030], [05-03-3050,03-05-5030], [06-03-3060,03-06-6030], [07-03-3070,03-07-7030], [08-03-3080,03-08-8030], [09-03-3090,03-09-9030], [10-13-3101,01-13-3110], [02-13-3120,10-23-3201], [02-13-3120,01-23-3210], [12-13-3121,11-23-3211], [04-13-3140,03-14-4130], [05-13-3150,03-15-5130], [06-13-3160,03-16-6130], [07-13-3170,03-17-7130], [08-13-3180,03-18-8130], [09-13-3190,03-19-9130], [10-23-3201,01-23-3210], [04-23-3240,03-24-4230], [05-23-3250,03-25-5230], [06-23-3260,03-26-6230], [07-23-3270,03-27-7230], [08-23-3280,03-28-8230], [09-23-3290,03-29-9230], [10-04-4001,01-04-4010], [11-04-4011,10-14-4101], [11-04-4011,01-14-4110], [12-04-4021,02-14-4120], [12-04-4021,10-24-4201], [12-04-4021,01-24-4210], [05-04-4050,04-05-5040], [06-04-4060,04-06-6040], [07-04-4070,04-07-7040], [08-04-4080,04-08-8040], [09-04-4090,04-09-9040], [10-14-4101,01-14-4110], [02-14-4120,10-24-4201], [02-14-4120,01-24-4210], [12-14-4121,11-24-4211], [05-14-4150,04-15-5140], [06-14-4160,04-16-6140], [07-14-4170,04-17-7140], [08-14-4180,04-18-8140], [09-14-4190,04-19-9140], [10-24-4201,01-24-4210], [05-24-4250,04-25-5240], [06-24-4260,04-26-6240], [07-24-4270,04-27-7240], [08-24-4280,04-28-8240], [09-24-4290,04-29-9240], [10-05-5001,01-05-5010], [11-05-5011,10-15-5101], [11-05-5011,01-15-5110], [12-05-5021,02-15-5120], [12-05-5021,10-25-5201], [12-05-5021,01-25-5210], [06-05-5060,05-06-6050], [07-05-5070,05-07-7050], [08-05-5080,05-08-8050], [09-05-5090,05-09-9050], [10-15-5101,01-15-5110], [02-15-5120,10-25-5201], [02-15-5120,01-25-5210], [12-15-5121,11-25-5211], [06-15-5160,05-16-6150], [07-15-5170,05-17-7150], [08-15-5180,05-18-8150], [09-15-5190,05-19-9150], [10-25-5201,01-25-5210], [06-25-5260,05-26-6250], [07-25-5270,05-27-7250], [08-25-5280,05-28-8250], [09-25-5290,05-29-9250], [10-06-6001,01-06-6010], [11-06-6011,10-16-6101], [11-06-6011,01-16-6110], [12-06-6021,02-16-6120], [12-06-6021,10-26-6201], [12-06-6021,01-26-6210], [07-06-6070,06-07-7060], [08-06-6080,06-08-8060], [09-06-6090,06-09-9060], [10-16-6101,01-16-6110], [02-16-6120,10-26-6201], [02-16-6120,01-26-6210], [12-16-6121,11-26-6211], [07-16-6170,06-17-7160], [08-16-6180,06-18-8160], [09-16-6190,06-19-9160], [10-26-6201,01-26-6210], [07-26-6270,06-27-7260], [08-26-6280,06-28-8260], [09-26-6290,06-29-9260], [10-07-7001,01-07-7010], [11-07-7011,10-17-7101], [11-07-7011,01-17-7110], [12-07-7021,02-17-7120], [12-07-7021,10-27-7201], [12-07-7021,01-27-7210], [08-07-7080,07-08-8070], [09-07-7090,07-09-9070], [10-17-7101,01-17-7110], [02-17-7120,10-27-7201], [02-17-7120,01-27-7210], [12-17-7121,11-27-7211], [08-17-7180,07-18-8170], [09-17-7190,07-19-9170], [10-27-7201,01-27-7210], [08-27-7280,07-28-8270], [09-27-7290,07-29-9270], [10-08-8001,01-08-8010], [11-08-8011,10-18-8101], [11-08-8011,01-18-8110], [12-08-8021,02-18-8120], [12-08-8021,10-28-8201], [12-08-8021,01-28-8210], [09-08-8090,08-09-9080], [10-18-8101,01-18-8110], [02-18-8120,10-28-8201], [02-18-8120,01-28-8210], [12-18-8121,11-28-8211], [09-18-8190,08-19-9180], [10-28-8201,01-28-8210], [09-28-8290,08-29-9280], [10-09-9001,01-09-9010], [11-09-9011,10-19-9101], [11-09-9011,01-19-9110], [12-09-9021,02-19-9120], [12-09-9021,10-29-9201], [12-09-9021,01-29-9210], [10-19-9101,01-19-9110], [02-19-9120,10-29-9201], [02-19-9120,01-29-9210], [12-19-9121,11-29-9211], [10-29-9201,01-29-9210]]

The differences in days of those pairs are:

yyyy-mm-dd: [3278, 328445, 331723, 6557, 328445, 335001, 693344, 696622, 9835, 328445, 338280, 1058239, 1061517, 325167, 328445, 328445, 361620, 364898, 3278, 328444, 331723, 361619, 368176, 693343, 726517, 729795, 6556, 328445, 335001, 361619, 371454, 1058238, 321888, 328444, 686787, 690065, 325166, 328445, 358341, 364898, 690065, 723239, 726517, 328445, 690065, 693344, 723239, 729796, 318610, 328445, 1048404, 1051682, 321889, 328445, 355063, 364898, 1051682, 328444, 693343, 719960, 729795, 1051682, 1054960, 328444, 1410024, 1413302, 328445, 364898, 1413302, 328445, 693344, 729796, 1413303, 1416581, 328445, 1771643, 1774921, 328445, 364898, 1774921, 328444, 693343, 729795, 1774921, 1778199, 328444, 2133263, 2136541, 328445, 364898, 2136541, 328445, 693344, 729796, 2136542, 2139820, 328445, 2494882, 2498160, 328445, 364898, 2498160, 328444, 693343, 729795, 2498160, 2501438, 328444, 2856502, 2859780, 328445, 364898, 2859780, 328445, 693344, 729796, 2859781, 2863059, 328445, 3218122, 3221400, 328445, 364898, 3221400, 328444, 693343, 729795, 3221400, 3224678, 3278, 6556, 364899, 368177, 9835, 729794, 733072, 33175, 36453, 3279, 33175, 39732, 364899, 398073, 401351, 6556, 33174, 43009, 729793, 358343, 361621, 29896, 36453, 361620, 394794, 398072, 361620, 364899, 394794, 401351, 719959, 723237, 26618, 36453, 723237, 364899, 391516, 401351, 723238, 726516, 1081580, 1084858, 36453, 1084857, 364899, 401351, 1084858, 1088136, 1443198, 1446476, 36453, 1446476, 364899, 401351, 1446477, 1449755, 1804819, 1808097, 36453, 1808096, 364899, 401351, 1808097, 1811375, 2166437, 2169715, 36453, 2169715, 364899, 401351, 2169716, 2172994, 2528058, 2531336, 36453, 2531335, 364899, 401351, 2531336, 2534614, 2889677, 2892955, 36453, 2892955, 364899, 401351, 2892956, 2896234, 3278, 6557, 331724, 364898, 368176, 9835, 696619, 3278, 364897, 325167, 358341, 361619, 361619, 361620, 364898, 686784, 358341, 364897, 1048404, 364898, 1410023, 364897, 1771643, 364898, 2133262, 364897, 2494882, 364898, 2856502, 364897, 3278, 6556, 33174, 36452, 3279, 33174, 39731, 29895, 36452, 355060, 361617, 26617, 36452, 358339, 361617, 361617, 716681, 723238, 36452, 719959, 723237, 723237, 1078299, 1084856, 36452, 1081578, 1084856, 1084856, 1439920, 1446477, 36452, 1443198, 1446476, 1446476, 1801538, 1808095, 36452, 1804817, 1808095, 1808095, 2163159, 2169716, 36452, 2166437, 2169715, 2169715, 2524778, 2531335, 36452, 2528057, 2531335, 2531335, 3278, 6557, 9835, 331722, 335000, 3278, 6556, 321887, 325165, 683507, 686785, 1045126, 1048404, 1406746, 1410024, 1768365, 1771643, 2129985, 2133263, 2491605, 2494883, 3278, 6557, 9835, 3278, 6556, 351785, 361620, 361620, 361621, 713404, 723239, 716683, 723239, 723239, 1075024, 1084859, 1084859, 1084860, 1436643, 1446478, 1439922, 1446478, 1446478, 1798263, 1808098, 1801542, 1808098, 1808099, 2159883, 2169718, 2169718, 2169718, 3278, 6557, 9835, 3278, 361619, 361619, 361618, 723239, 723239, 723239, 1084858, 1084858, 1084857, 1446478, 1446478, 1446478, 1808098, 1808098, 1808097, 3278, 6557, 9835, 3278, 6556, 361620, 361620, 361621, 723239, 723239, 723239, 1084859, 1084859, 1084860, 1446479, 1446479, 1446479, 3278, 6557, 9835, 3278, 361619, 361619, 361618, 723239, 723239, 723239, 1084859, 1084859, 1084858, 3278, 6557, 9835, 3278, 6556, 361620, 361620, 361621, 723240, 723240, 723240, 3278, 6557, 9835, 3278, 6556, 361620, 361620, 361619, 3278, 6557, 9835, 3278]
mm-dd-yyyy: [3014, 328709, 331723, 325695, 328709, 328709, 361560, 364574, 29837, 32851, 328709, 687256, 690270, 32851, 328709, 364574, 394412, 397426, 690270, 723121, 726135, 62690, 65704, 328709, 1048818, 1051832, 328709, 1410378, 1413392, 328709, 1771939, 1774953, 328709, 2133499, 2136513, 328709, 2495060, 2498074, 328709, 2856620, 2859634, 328709, 3218180, 3221194, 3014, 298872, 657419, 660433, 295858, 654405, 657419, 295858, 331723, 361561, 364575, 657419, 690270, 693284, 657419, 364575, 657419, 693284, 723121, 726135, 657419, 1018981, 657419, 1380541, 657419, 1742102, 657419, 2103662, 657419, 2465223, 657419, 2826783, 657419, 3188343, 3014, 266019, 986128, 989142, 263005, 983114, 986128, 298870, 361561, 364575, 986128, 1018979, 1021993, 331722, 660431, 986128, 1021993, 1051831, 1054845, 986128, 986128, 1347688, 986128, 1709249, 986128, 2070809, 986128, 2432370, 986128, 2793930, 986128, 3155490, 3014, 32851, 35865, 358547, 361561, 35865, 65703, 68717, 361561, 394412, 397426, 720109, 723123, 1081669, 1084683, 1443230, 1446244, 1804790, 1807804, 2166351, 2169365, 2527911, 2530925, 2889471, 2892485, 3014, 29838, 32852, 325696, 358547, 361561, 32852, 361561, 62691, 65705, 687258, 720109, 723123, 1048818, 1081669, 1084683, 1410379, 1443230, 1446244, 1771939, 1804790, 1807804, 2133500, 2166351, 2169365, 2495060, 2527911, 2530925, 2856620, 2889471, 2892485, 3014, 295858, 328709, 331723, 292844, 325695, 328709, 328709, 292844, 328709, 358546, 361560, 328709, 361560, 328709, 654406, 690271, 720109, 723123, 328709, 1015966, 1051831, 1081668, 1084682, 328709, 1377527, 1413392, 1443230, 1446244, 328709, 1739087, 1774952, 1804789, 1807803, 328709, 2100648, 2136513, 2166351, 2169365, 328709, 2462208, 2498073, 2527910, 2530924, 328709, 2823768, 2859633, 2889471, 2892485, 3014, 624567, 657418, 660432, 621553, 654404, 657418, 657418, 690270, 657418, 657418, 1380539, 657418, 2103660, 657418, 2465220, 3014, 32851, 35865, 35865, 65702, 68716, 361562, 723122, 1084683, 1446243, 1807804, 2169364, 2530924, 3014, 29837, 32851, 32851, 325697, 361562, 391400, 394414, 687257, 723122, 752959, 755973, 1048818, 1084683, 1114521, 1117535, 1410378, 1446243, 1476080, 1479094, 1771939, 1807804, 1837642, 1840656, 2133499, 2169364, 2199201, 2202215, 2495059, 2530924, 2560762, 2563776, 3014, 361563, 723122, 1084684, 1446243, 1807805, 2169364, 2530925, 3014, 32851, 35865, 35865, 65703, 68717, 361560, 723121, 1084681, 1446242, 1807802, 2169362, 3014, 29838, 32852, 32852, 361560, 723121, 1084681, 1446242, 1807802, 2169362, 3014, 361559, 723121, 1084680, 1446242, 1807801, 2169362, 3014, 32851, 35865, 35865, 65702, 68716, 361561, 723121, 1084682, 1446242, 1807802, 3014, 29837, 32851, 32851, 361561, 723121, 1084682, 1446242, 1807802, 3014, 361562, 723121, 1084683, 1446242, 1807803, 3014, 32851, 35865, 35865, 65703, 68717, 361560, 723121, 1084681, 1446241, 3014, 29838, 32852, 32852, 361560, 723121, 1084681, 1446241, 3014, 361559, 723121, 1084680, 1446241, 3014, 32851, 35865, 35865, 65702, 68716, 361561, 723121, 1084681, 3014, 29837, 32851, 32851, 361561, 723121, 1084681, 3014, 361562, 723121, 1084682, 3014, 32851, 35865, 35865, 65703, 68717, 361560, 723120, 3014, 29838, 32852, 32852, 361560, 723120, 3014, 361559, 723120, 3014, 32851, 35865, 35865, 65702, 68716, 361560, 3014, 29837, 32851, 32851, 361560, 3014, 361561, 3014, 32851, 35865, 35865, 65703, 68717, 3014, 29838, 32852, 32852, 3014]

And none of those differences are palindromes, so there won't be any output for either of these two formats.

(See my Java answer for an answer using format dd-mm-yyyy like the challenge description, which I've also used to generate the lists above.)

Kevin Cruijssen

Posted 2020-02-27T12:18:20.860

Reputation: 67 575

I found a similar solution to your Polyglot one in Golfscript - I'm going to see if I can make it work in Python next! – Mathgeek – 2020-02-27T14:14:18.637

1@Mathgeek Polyglot means it works in all languages, including Golfscript and Python. ;) – Kevin Cruijssen – 2020-02-27T14:15:16.737

3I'm aware, [I'm being intentionally dense for comedic value] ;p – Mathgeek – 2020-02-27T14:17:32.523

Doesn't this violate a couple of the the standard loopholes like this or maybe this

– Xcali – 2020-02-27T23:53:57.463

1@Xcali, we also have a consensus somewhere that proofs of "impossibility" are valid. – Shaggy – 2020-02-28T00:31:38.393

@Xcali Shaggy is indeed correct: Is a proof of impossibility allowed as an answer? Although that meta question is mainly directed to challenges with no valid solutions at all, so I guess there is a fine line in this challenge where alternative formats do give proper outputs.

– Kevin Cruijssen – 2020-02-28T07:19:11.953

3

Red, 305 bytes

p: func[s n][at to""10 ** n + s 2]s: func[d][rejoin[p d/4 2 p d/3 2 p d/2 4]]
r: func[s][s: to""s s = reverse copy s]a: to-date[1 1 1]b:
collect[until[if r s a[keep a]a: a + 1 a/2 = 1e4]]repeat i l: length? b[repeat
j l[if all[i < j(sort s b/:i)= sort s b/:j
r t: b/:j - b/:i][print[s b/:i s b/:j"::"t]]]]

Try it online!

In dd-mm-yyyy format. I'm listing the pairs only once. Currently there is no separator in the dates - I'll fix it if it's necessary.

Galen Ivanov

Posted 2020-02-27T12:18:20.860

Reputation: 13 815

3

JavaScript (ES6),  115 109  108 bytes

Date format: dd-mm-yyyy.

_=>[-1102,-1101,-2,0,2,4,5,7,9].map(y=>([,a,b,c,d]=y+11303+'',[a+b+(m='-'+c+d+'-'+d+c)+b+a,b+a+m+a+b,6556]))

Try it online!

Arnauld

Posted 2020-02-27T12:18:20.860

Reputation: 111 334

Well done but 31-09-9013 does not exist in the current calendar – Regis Portalez – 2020-02-27T15:23:54.203

@RegisPortalez My bad. Now fixed. – Arnauld – 2020-02-27T15:31:17.083

2

Uses format ddmmyyyy for the palindrome checks like the challenge description.

Java 8 (hard-coded), 190 bytes

v->"31100113 13100131x20011002 02011020x31011013 13011031x20022002 02022020x31122113 13122131x31033013 13033031x31055013 13055031x31077013 13077031x31088013 13088031x".replace("x"," 6556\n")

As expected, a lot shorter than calculating it..
Outputs in the format ddmmyyyy.

Try it online.

Explanation:

v->   // Method with empty unused parameter and String return-type
  "31100113 13100131x20011002 02011020x31011013 13011031x20022002 02022020x31122113 13122131x31033013 13033031x31055013 13055031x31077013 13077031x31088013 13088031x"
      //  Return this String
    .replace("x"," 6556\n")
      //  after we've replaced all "x" with " 6556\n"

Java 10 (calculated), 524 486 476 bytes

import java.time.*;v->{var D=LocalDate.of(1,1,1);java.util.Arrays A=null;var L=D.datesUntil(D.of(10000,1,1)).filter(d->{var s=(d+"").split("-");return p(s[2]+s[1]+s[0]);}).toArray(LocalDate[]::new);for(var a:L)for(var b:L){var x=(a+"").split("");var y=(b+"").split("");A.sort(x);A.sort(y);var d=a.until(b,java.time.temporal.ChronoUnit.DAYS);if(d>0&A.equals(x,y)&p(d+""))System.out.println(a+" "+b+" "+d);}}boolean p(String s){return s.contains(new StringBuffer(s).reverse());}

Uses the same format as in the challenge description for the checks ddmmyyyy, but outputs as format yyyy-mm-dd.

Try it online.

Explanation:

import java.time.*;       // Import for both LocalDate
v->{                      // Method with empty unused parameter and no return-type
  var D=LocalDate.of(1,1,1);
                          //  LocalDate variable to save bytes, with date 01-01-0001
  java.util.Arrays A=null;//  Static Arrays to save bytes
  var L=D.datesUntil(D.of(10000,1,1))
                          //  Create a stream of dates in the range [01-01-0001,01-01-9999]:
        .filter(d->{      //  Filter it by:
          var s=(d+"")    //   Convert the date to a String in the format "yyyy-mm-dd"
            .split("-");  //   And split it at the "-"
      return p(s[2]+s[1]+s[0]);})
                          //   Return whether "ddmmyyyy" is a palindrome
        .toArray(LocalDate[]::new);
                          //  And convert that filtered stream to an array of LocalDates
for(var a:L)for(var b:L){ //  Nested loop over all these dates a,b:
  var x=(a+"")            //   Convert date `a` to a String,
        .split("");       //   and then into an array of characters
  var y=(b+"").split(""); //   Do the same for date `b`
  A.sort(x);A.sort(y);    //   Sort the characters in both arrays
  var d=a.until(b,java.time.temporal.ChronoUnit.DAYS);
                          //   Get the difference in days between the two dates
  if(d>0                  //   If this difference is larger than 0,
                          //   (which means a is before b, and they are not the same)
     &A.equals(x,y)       //   and the two sorted character-arrays are equal,
                          //   (which means a and b are anagrams)
     &p(d+""))            //   and the difference is a palindrome:
    System.out.println(a+" "+b+" "+d);}}
                          //    Print the pair a,b and difference with trailing newline

// Separated method to check if a String is a palindrome:
boolean p(String s){      // Method with String parameter and boolean return-type
  return s.contains(      //  Return whether the input-string contains:
    new StringBuffer(s).reverse());}
                          //   The reversed input-String(Buffer)

Kevin Cruijssen

Posted 2020-02-27T12:18:20.860

Reputation: 67 575

1

[HARCODED]

PHP, 194 bytes

<?=str_replace("x"," 6556
","31100113 13100131x20011002 02011020x31011013 13011031x20022002 02022020x31122113 13122131x31033013 13033031x31055013 13055031x31077013 13077031x31088013 13088031x");

Try it online!

[WITH CAUTION]: shorter version that assumes following Kevin Cruijssen's results (I haven't verified them) that the difference in days will always be 6556:

PHP, 223 bytes

$a=date_create('0000-12-31');for(;($c=($d=clone$a->modify('+1day'))->format('dmY'))!=31129999;)if($c==strrev($c)&($e=$d->modify('+6556day')->format('dmY'))==strrev($e)&count_chars($c,1)==count_chars($e,1))echo"$c $e 6556
";

Try it online!

[FULL VERSION THAT CALCULATES WITH ALL DATES]:

PHP, 283 bytes

$a=date_create('0000-12-31');for(;($c=($d=clone$a->modify('+1day'))->format('dmY'))!=31129999;){for(;($e=$d->modify('+1day')->format('dmY'))!=31129999;)if($c==strrev($c)&$e==strrev($e)&count_chars($c,1)==count_chars($e,1)&($f=$d->diff($a)->format('%a'))==strrev($f))echo"$c $e $f
";}

Try it online!

Dates format is dd-mm-yyyy, pairs are displayed in one order only. formats the inputs like dd-mm-yyyy dd-mm-yyyy n but doesn't separate them (count 1 bytes more for a new line).

Actually times out pretty quick.. cannot even check the first result in TIO. Note that the date 31-12-9999 is never tested (loops pre-increment), but it doesn't matter because it's not a palindrome anyway..

EDIT: added hardcoded version (port of Kevin Cruijssen's) + switched to format ddmmyyyy (without -) with a new line for the other versions

Kaddath

Posted 2020-02-27T12:18:20.860

Reputation: 449

0

05AB1E, 39 bytes

31 9и20₂S;ǝDí«•1/K†Þ'āD•2×2ôøJº2äøŽP¶δª

05AB1E doesn't even have any date buitlins, so hard-coded it is. ;)
Uses and outputs in format ddmmyyyy. Outputs as a list of triplets.

Try it online (the » in the footer is to pretty-print them, but feel free to remove it to see the actual output).

Explanation:

31             # Push 31
   9и          # Repeat it 9 times as list: [31,31,31,31,31,31,31,31,31]
     20        # Push 20
       ₂S      # Push builtin 26 as digit list: [2,6]
         ;     # Halve each: [1,3]
          ǝ    # Insert 20 at both those (0-based) indices: [31,20,31,20,31,31,31,31,31]
           D   # Duplicate this list
            í  # Reverse each: [13,"02",13,"02",13,13,13,13,13]
             « # Merge the two lists together:
               #  [31,20,31,20,31,31,31,31,31,13,"02",13,"02",13,13,13,13,13]
•1/K†Þ'āD•    '# Push compressed integer 100101021203050708
          2×   # Double this as string: "100101021203050708100101021203050708"
            2ô # Split it into parts of size 2:
               #  [10,"01","01","02",12,"03","05","07","08",10,"01","01","02",12,"03","05","07","08"]
ø              # Zip the two lists together, creating pairs:
               #  [[31,10],[20,"01"],[31,"01"],[20,"02"],[31,12],[31,"03"],...]
 J             # Join each pair together to a string: [3110,2001,3101,2002,3112,3103,...]
  º            # Mirror each: [31100113,20011002,31011013,20022002,31122113,31033013,...]
   2ä          # Split the list into two equal parts (of size 9)
     ø         # Zip/transpose it, swapping rows/columns:
               #   [[31100113,13100131],[20011002,"02011020"],[31011013,13011031],...]
      ŽP¶      # Push compressed integer 6556
         δª    # And append it to each pair to create triplets
               # (after which that list of triplets is output implicitly as result)

See this 05AB1E tip of mine (section How to compress large integers?) to understand why •1/K†Þ'āD• is 100101021203050708 and ŽP¶ is 6556.

Kevin Cruijssen

Posted 2020-02-27T12:18:20.860

Reputation: 67 575