package conventions

class DateRange(private val start: MyDate, private val endInclusive: MyDate) {

    //operator fun contains(item: MyDate): Boolean = item in start..endInclusive
    operator fun contains(item: MyDate) = start <= item && item <= endInclusive
}

fun checkInRange(date: MyDate, first: MyDate, last: MyDate): Boolean {
    return date in DateRange(first, last)
}