toEnglishDafGemara

fun Int.toEnglishDafGemara(): String

Converts an integer representing a Daf Gemara (Talmudic page) to its corresponding English representation.

The function takes an integer input and converts it into the format "{Daf}{Amoud}". The Daf is calculated based on the input number, with the Daf numbering starting at 2. The Amoud (side) is determined based on whether the input number is odd or even:

  • Odd numbers correspond to "a".

  • Even numbers correspond to "b".

Receiver

Int The integer representing the Daf Gemara. It must be a non-negative integer.

Return

A string representing the Daf Gemara in the English format "{Daf}{Amoud}", where {Daf} is the Daf number starting at 2, and {Amoud} is either "a" or "b" based on the odd/even nature of the input number.

Throws

IllegalArgumentException

If the integer is negative.