distanceFrom method

int distanceFrom(
  1. Date other
)

distance between two dates

d1.distanceFrom(d2) is equivalent to d1 ^ d2 and mathematically equivalent to d1 minus d2

Implementation

int distanceFrom(Date other) {
  return julianDayNumber - other.julianDayNumber;
}