After implementing the difficult date and time parsing for Microsoft, you managed to find yourself elsewhere and elsewhen. (Or maybe you failed to implement such a trivial function, in which case you deserve what's coming next.)
Somehow, you managed to find yourself in Paris, during the height of Maximilien Robespierre's Reign of Terror. You were brought before said Maximilien Robespierre, and offered your services as a programmer to avoid being guillotined as a spy by the Committee of Public Safety. As Robespierre had already guillotined astronomers responsible for maintaining the calendar, he decided to let you maintain the calendar with your programming skills. Of course, if you fail this task, you would obviously be seen as a traitor and inevitably face the guillotine.
Now, recall that the French Republican calendar consists of 12 months of 30 days each, followed by 5 complementary days (6 in leap years). The 12 months are, in order: Vendémiaire, Brumaire, Frimaire, Nivôse, Pluviôse, Ventôse, Germinal, Floréal, Prairial, Messidor, Thermidor, Fructidor. The five complementary days are: la Fête de la Vertu, la Fête du Génie, la Fête du Travail, la Fête de l'Opinion, la Fête des Récompenses. On leap years, la Fête de la Révolution is added. The first day of the year in the French Republican calendar is 1 Vendémiaire, and the autumnal equinox using the mean solar time in Paris Observatory (longitude 2°20′14.03″ E) must fall on that date.
Unfortunately, you don't actually know anything about astronomy. Fortunately for you, you were lucky enough to find a copy of JPL's latest development ephemeris on your laptop along with a copy of the skyfield
library, which can tell you the exact time of the autumnal equinox for any year in the next ten thousand years. This could save your life, if you know how to do some basic math.
Input Specification
The input will contain two lines. The first line will be the time of the autumnal equinox of the year to generate the calendar for, i.e. this moment will be part of 1 Vendémiaire. The next line will contain the time of the autumnal equinox of the year after.
These times will be given in the ISO 8601 format using the Gregorian calendar, i.e. YYYY-mm-ddTHH:MM:SS
. However, to spare you the trouble of dealing with leap seconds, the times are given in UT1. The year may have more than 4 digits, but its range is restricted to .
Output Specification
Output the list of dates of the year, and their corresponding dates in the Gregorian calendar. Your output should be encoded as UTF-8 with NFC normalization.
Sample Input
2021-09-22T19:21:05
2022-09-23T01:03:42
Sample Output
L'an 230 de la république française
1 Vendémiaire: 2021-09-22
2 Vendémiaire: 2021-09-23
3 Vendémiaire: 2021-09-24
4 Vendémiaire: 2021-09-25
5 Vendémiaire: 2021-09-26
6 Vendémiaire: 2021-09-27
7 Vendémiaire: 2021-09-28
8 Vendémiaire: 2021-09-29
9 Vendémiaire: 2021-09-30
10 Vendémiaire: 2021-10-01
11 Vendémiaire: 2021-10-02
12 Vendémiaire: 2021-10-03
13 Vendémiaire: 2021-10-04
14 Vendémiaire: 2021-10-05
15 Vendémiaire: 2021-10-06
16 Vendémiaire: 2021-10-07
17 Vendémiaire: 2021-10-08
18 Vendémiaire: 2021-10-09
19 Vendémiaire: 2021-10-10
20 Vendémiaire: 2021-10-11
21 Vendémiaire: 2021-10-12
22 Vendémiaire: 2021-10-13
23 Vendémiaire: 2021-10-14
24 Vendémiaire: 2021-10-15
25 Vendémiaire: 2021-10-16
26 Vendémiaire: 2021-10-17
27 Vendémiaire: 2021-10-18
28 Vendémiaire: 2021-10-19
29 Vendémiaire: 2021-10-20
30 Vendémiaire: 2021-10-21
1 Brumaire: 2021-10-22
2 Brumaire: 2021-10-23
3 Brumaire: 2021-10-24
4 Brumaire: 2021-10-25
5 Brumaire: 2021-10-26
6 Brumaire: 2021-10-27
7 Brumaire: 2021-10-28
8 Brumaire: 2021-10-29
9 Brumaire: 2021-10-30
10 Brumaire: 2021-10-31
11 Brumaire: 2021-11-01
12 Brumaire: 2021-11-02
13 Brumaire: 2021-11-03
14 Brumaire: 2021-11-04
15 Brumaire: 2021-11-05
16 Brumaire: 2021-11-06
17 Brumaire: 2021-11-07
18 Brumaire: 2021-11-08
19 Brumaire: 2021-11-09
20 Brumaire: 2021-11-10
21 Brumaire: 2021-11-11
22 Brumaire: 2021-11-12
23 Brumaire: 2021-11-13
24 Brumaire: 2021-11-14
25 Brumaire: 2021-11-15
26 Brumaire: 2021-11-16
27 Brumaire: 2021-11-17
28 Brumaire: 2021-11-18
29 Brumaire: 2021-11-19
30 Brumaire: 2021-11-20
1 Frimaire: 2021-11-21
2 Frimaire: 2021-11-22
3 Frimaire: 2021-11-23
4 Frimaire: 2021-11-24
5 Frimaire: 2021-11-25
6 Frimaire: 2021-11-26
7 Frimaire: 2021-11-27
8 Frimaire: 2021-11-28
9 Frimaire: 2021-11-29
10 Frimaire: 2021-11-30
11 Frimaire: 2021-12-01
12 Frimaire: 2021-12-02
13 Frimaire: 2021-12-03
14 Frimaire: 2021-12-04
15 Frimaire: 2021-12-05
16 Frimaire: 2021-12-06
17 Frimaire: 2021-12-07
18 Frimaire: 2021-12-08
19 Frimaire: 2021-12-09
20 Frimaire: 2021-12-10
21 Frimaire: 2021-12-11
22 Frimaire: 2021-12-12
23 Frimaire: 2021-12-13
24 Frimaire: 2021-12-14
25 Frimaire: 2021-12-15
26 Frimaire: 2021-12-16
27 Frimaire: 2021-12-17
28 Frimaire: 2021-12-18
29 Frimaire: 2021-12-19
30 Frimaire: 2021-12-20
1 Nivôse: 2021-12-21
2 Nivôse: 2021-12-22
3 Nivôse: 2021-12-23
4 Nivôse: 2021-12-24
5 Nivôse: 2021-12-25
6 Nivôse: 2021-12-26
7 Nivôse: 2021-12-27
8 Nivôse: 2021-12-28
9 Nivôse: 2021-12-29
10 Nivôse: 2021-12-30
11 Nivôse: 2021-12-31
12 Nivôse: 2022-01-01
13 Nivôse: 2022-01-02
14 Nivôse: 2022-01-03
15 Nivôse: 2022-01-04
16 Nivôse: 2022-01-05
17 Nivôse: 2022-01-06
18 Nivôse: 2022-01-07
19 Nivôse: 2022-01-08
20 Nivôse: 2022-01-09
21 Nivôse: 2022-01-10
22 Nivôse: 2022-01-11
23 Nivôse: 2022-01-12
24 Nivôse: 2022-01-13
25 Nivôse: 2022-01-14
26 Nivôse: 2022-01-15
27 Nivôse: 2022-01-16
28 Nivôse: 2022-01-17
29 Nivôse: 2022-01-18
30 Nivôse: 2022-01-19
1 Pluviôse: 2022-01-20
2 Pluviôse: 2022-01-21
3 Pluviôse: 2022-01-22
4 Pluviôse: 2022-01-23
5 Pluviôse: 2022-01-24
6 Pluviôse: 2022-01-25
7 Pluviôse: 2022-01-26
8 Pluviôse: 2022-01-27
9 Pluviôse: 2022-01-28
10 Pluviôse: 2022-01-29
11 Pluviôse: 2022-01-30
12 Pluviôse: 2022-01-31
13 Pluviôse: 2022-02-01
14 Pluviôse: 2022-02-02
15 Pluviôse: 2022-02-03
16 Pluviôse: 2022-02-04
17 Pluviôse: 2022-02-05
18 Pluviôse: 2022-02-06
19 Pluviôse: 2022-02-07
20 Pluviôse: 2022-02-08
21 Pluviôse: 2022-02-09
22 Pluviôse: 2022-02-10
23 Pluviôse: 2022-02-11
24 Pluviôse: 2022-02-12
25 Pluviôse: 2022-02-13
26 Pluviôse: 2022-02-14
27 Pluviôse: 2022-02-15
28 Pluviôse: 2022-02-16
29 Pluviôse: 2022-02-17
30 Pluviôse: 2022-02-18
1 Ventôse: 2022-02-19
2 Ventôse: 2022-02-20
3 Ventôse: 2022-02-21
4 Ventôse: 2022-02-22
5 Ventôse: 2022-02-23
6 Ventôse: 2022-02-24
7 Ventôse: 2022-02-25
8 Ventôse: 2022-02-26
9 Ventôse: 2022-02-27
10 Ventôse: 2022-02-28
11 Ventôse: 2022-03-01
12 Ventôse: 2022-03-02
13 Ventôse: 2022-03-03
14 Ventôse: 2022-03-04
15 Ventôse: 2022-03-05
16 Ventôse: 2022-03-06
17 Ventôse: 2022-03-07
18 Ventôse: 2022-03-08
19 Ventôse: 2022-03-09
20 Ventôse: 2022-03-10
21 Ventôse: 2022-03-11
22 Ventôse: 2022-03-12
23 Ventôse: 2022-03-13
24 Ventôse: 2022-03-14
25 Ventôse: 2022-03-15
26 Ventôse: 2022-03-16
27 Ventôse: 2022-03-17
28 Ventôse: 2022-03-18
29 Ventôse: 2022-03-19
30 Ventôse: 2022-03-20
1 Germinal: 2022-03-21
2 Germinal: 2022-03-22
3 Germinal: 2022-03-23
4 Germinal: 2022-03-24
5 Germinal: 2022-03-25
6 Germinal: 2022-03-26
7 Germinal: 2022-03-27
8 Germinal: 2022-03-28
9 Germinal: 2022-03-29
10 Germinal: 2022-03-30
11 Germinal: 2022-03-31
12 Germinal: 2022-04-01
13 Germinal: 2022-04-02
14 Germinal: 2022-04-03
15 Germinal: 2022-04-04
16 Germinal: 2022-04-05
17 Germinal: 2022-04-06
18 Germinal: 2022-04-07
19 Germinal: 2022-04-08
20 Germinal: 2022-04-09
21 Germinal: 2022-04-10
22 Germinal: 2022-04-11
23 Germinal: 2022-04-12
24 Germinal: 2022-04-13
25 Germinal: 2022-04-14
26 Germinal: 2022-04-15
27 Germinal: 2022-04-16
28 Germinal: 2022-04-17
29 Germinal: 2022-04-18
30 Germinal: 2022-04-19
1 Floréal: 2022-04-20
2 Floréal: 2022-04-21
3 Floréal: 2022-04-22
4 Floréal: 2022-04-23
5 Floréal: 2022-04-24
6 Floréal: 2022-04-25
7 Floréal: 2022-04-26
8 Floréal: 2022-04-27
9 Floréal: 2022-04-28
10 Floréal: 2022-04-29
11 Floréal: 2022-04-30
12 Floréal: 2022-05-01
13 Floréal: 2022-05-02
14 Floréal: 2022-05-03
15 Floréal: 2022-05-04
16 Floréal: 2022-05-05
17 Floréal: 2022-05-06
18 Floréal: 2022-05-07
19 Floréal: 2022-05-08
20 Floréal: 2022-05-09
21 Floréal: 2022-05-10
22 Floréal: 2022-05-11
23 Floréal: 2022-05-12
24 Floréal: 2022-05-13
25 Floréal: 2022-05-14
26 Floréal: 2022-05-15
27 Floréal: 2022-05-16
28 Floréal: 2022-05-17
29 Floréal: 2022-05-18
30 Floréal: 2022-05-19
1 Prairial: 2022-05-20
2 Prairial: 2022-05-21
3 Prairial: 2022-05-22
4 Prairial: 2022-05-23
5 Prairial: 2022-05-24
6 Prairial: 2022-05-25
7 Prairial: 2022-05-26
8 Prairial: 2022-05-27
9 Prairial: 2022-05-28
10 Prairial: 2022-05-29
11 Prairial: 2022-05-30
12 Prairial: 2022-05-31
13 Prairial: 2022-06-01
14 Prairial: 2022-06-02
15 Prairial: 2022-06-03
16 Prairial: 2022-06-04
17 Prairial: 2022-06-05
18 Prairial: 2022-06-06
19 Prairial: 2022-06-07
20 Prairial: 2022-06-08
21 Prairial: 2022-06-09
22 Prairial: 2022-06-10
23 Prairial: 2022-06-11
24 Prairial: 2022-06-12
25 Prairial: 2022-06-13
26 Prairial: 2022-06-14
27 Prairial: 2022-06-15
28 Prairial: 2022-06-16
29 Prairial: 2022-06-17
30 Prairial: 2022-06-18
1 Messidor: 2022-06-19
2 Messidor: 2022-06-20
3 Messidor: 2022-06-21
4 Messidor: 2022-06-22
5 Messidor: 2022-06-23
6 Messidor: 2022-06-24
7 Messidor: 2022-06-25
8 Messidor: 2022-06-26
9 Messidor: 2022-06-27
10 Messidor: 2022-06-28
11 Messidor: 2022-06-29
12 Messidor: 2022-06-30
13 Messidor: 2022-07-01
14 Messidor: 2022-07-02
15 Messidor: 2022-07-03
16 Messidor: 2022-07-04
17 Messidor: 2022-07-05
18 Messidor: 2022-07-06
19 Messidor: 2022-07-07
20 Messidor: 2022-07-08
21 Messidor: 2022-07-09
22 Messidor: 2022-07-10
23 Messidor: 2022-07-11
24 Messidor: 2022-07-12
25 Messidor: 2022-07-13
26 Messidor: 2022-07-14
27 Messidor: 2022-07-15
28 Messidor: 2022-07-16
29 Messidor: 2022-07-17
30 Messidor: 2022-07-18
1 Thermidor: 2022-07-19
2 Thermidor: 2022-07-20
3 Thermidor: 2022-07-21
4 Thermidor: 2022-07-22
5 Thermidor: 2022-07-23
6 Thermidor: 2022-07-24
7 Thermidor: 2022-07-25
8 Thermidor: 2022-07-26
9 Thermidor: 2022-07-27
10 Thermidor: 2022-07-28
11 Thermidor: 2022-07-29
12 Thermidor: 2022-07-30
13 Thermidor: 2022-07-31
14 Thermidor: 2022-08-01
15 Thermidor: 2022-08-02
16 Thermidor: 2022-08-03
17 Thermidor: 2022-08-04
18 Thermidor: 2022-08-05
19 Thermidor: 2022-08-06
20 Thermidor: 2022-08-07
21 Thermidor: 2022-08-08
22 Thermidor: 2022-08-09
23 Thermidor: 2022-08-10
24 Thermidor: 2022-08-11
25 Thermidor: 2022-08-12
26 Thermidor: 2022-08-13
27 Thermidor: 2022-08-14
28 Thermidor: 2022-08-15
29 Thermidor: 2022-08-16
30 Thermidor: 2022-08-17
1 Fructidor: 2022-08-18
2 Fructidor: 2022-08-19
3 Fructidor: 2022-08-20
4 Fructidor: 2022-08-21
5 Fructidor: 2022-08-22
6 Fructidor: 2022-08-23
7 Fructidor: 2022-08-24
8 Fructidor: 2022-08-25
9 Fructidor: 2022-08-26
10 Fructidor: 2022-08-27
11 Fructidor: 2022-08-28
12 Fructidor: 2022-08-29
13 Fructidor: 2022-08-30
14 Fructidor: 2022-08-31
15 Fructidor: 2022-09-01
16 Fructidor: 2022-09-02
17 Fructidor: 2022-09-03
18 Fructidor: 2022-09-04
19 Fructidor: 2022-09-05
20 Fructidor: 2022-09-06
21 Fructidor: 2022-09-07
22 Fructidor: 2022-09-08
23 Fructidor: 2022-09-09
24 Fructidor: 2022-09-10
25 Fructidor: 2022-09-11
26 Fructidor: 2022-09-12
27 Fructidor: 2022-09-13
28 Fructidor: 2022-09-14
29 Fructidor: 2022-09-15
30 Fructidor: 2022-09-16
La Fête de la Vertu: 2022-09-17
La Fête du Génie: 2022-09-18
La Fête du Travail: 2022-09-19
La Fête de l'Opinion: 2022-09-20
La Fête des Récompenses: 2022-09-21
La Fête de la Révolution: 2022-09-22
Sample output reduced to save your paper. Please visit https://dmoj.ca/problem/calendar5 for the full sample output.
Comments