static long daysElapsed(const struct tm *now, const struct tm *last)
{
    const double diff = difftime(mktimeFromDateOnly(now),mktimeFromDateOnly(last));
    return (long) (diff / (24 * 3600));
}
static long daysElapsed(const struct tm *now, const struct tm *last)
{
    const double diff = difftime(mktimeFromDateOnly(now),mktimeFromDateOnly(last));
    return (long) (diff / (24 * 3600));
}