The Venerable Bede, 21st Century Style

1

1300 years ago, the English theologian Bede earned the honorific by which he is now known ("The Venerable Bede") by, among other things, convincingly computing the date of Easter for a number of years. This required reconciling the old, Jewish, lunar calendar with the newer solar one, a task made all the more challenging by the fact that Bede did all his math using Roman numerals.

Challenge

In honor of this, your challenge is to produce code that takes a year in Roman numerals, computes the date of Easter for that year and returns it, again in Roman numerals.

Rules

  1. No pre-computing and caching the dates, calling a built-in 'date of easter' or 'holiday dates' function or library, or looking them up online.
  2. Your code should work for any year between MCM and MMXCIX
  3. Helpful algorithms can be found at https://en.wikipedia.org/wiki/Computus
  4. Output can be in YEAR-MONTH-DAY format, or {YEAR, MONTH, DAY} or any similar arrangement as is convenient in your programming language of choice.
  5. You can assume that the input year has already been assigned to a variable x.
  6. Your code should not crash if this input is invalid as a Roman numeral. Quit gracefully.
  7. Where proper Roman representation is ambiguous (as with "IV" vs. "IIII"), follow the guidelines at http://literacy.kent.edu/Minigrants/Cinci/romanchart.htm

Scoring

Shortest program in bytes wins, subject to the following adjustment: if you do your internal math in Roman numerals, in addition to input and output, subtract 90% off of your byte count. I believe that this bonus will suffice to make this question more interesting than a normal 'find the date of easter' question.

Michael Stern

Posted 2015-07-14T16:50:09.713

Reputation: 3 029

Question was closed 2015-07-14T22:06:02.713

7

Example input/output would probably be good here, especially since there will be discrepancies in the output depending on which calendar you follow. Also, can we assume additive form like IIII instead of IV?

– Sp3000 – 2015-07-14T17:06:33.320

5Also, I don't think the bonus makes any sense. It's almost impossible to do the arithmetic without using ints in there somewhere, whether it be working out that V -> 5 or counting the number of Is in the input string... (I guess you could define "I" + "I" = "II", "I" + "II" = "III"... but that'd be far too long) – Sp3000 – 2015-07-14T17:18:11.017

4Why is the year needed in the output, when it is given as the input? – feersum – 2015-07-14T17:35:55.347

@SP3000 the math was originally done, 1300 years ago, without arabic numerals. Surely modern computer hardware can match the feat of early medieval monks. – Michael Stern – 2015-07-14T18:00:40.893

@SP3000 clarified IIII vs IV and a few other things. – Michael Stern – 2015-07-14T18:06:18.630

2

The core calculation is Calculate the date of Easter, and changing I/O formats doesn't generally distinguish a question enough to not count as a dupe. In this case, it's a non-trivial format change, but the format change is also a dupe of existing questions.

– Peter Taylor – 2015-07-14T18:16:13.657

@Sp3000 The way I read the bonus rule, the code can be 10 times as long if you operate in roman. While it looks painful, the amount of the bonus is generous enough to potentially make it interesting. – Reto Koradi – 2015-07-14T18:22:21.763

No answers