Perl Monk, Perl Meditation | |
PerlMonks |
Re^3: DateCalc using Date::Manipby SBECK (Chaplain) |
on Jan 11, 2017 at 16:50 UTC ( [id://1179408]=note: print w/replies, xml ) | Need Help?? |
I don't have a 'semi-exact' mode in Date::Manip... but what you're really saying is: convert an exact delta to a semi-approximate one. This is of course different from coming up with an semi-approximate delta from two dates (which is what I was doing... I should have noticed that it wasn't exactly what the OP was doing, but I got ahead of myself after noticing I couldn't use 'semi' mode in the older DateCalc). In any case, you can do the following:
which yields:
So you can see how to convert an exact delta to a semi-approximate one using either the old or new interfaces.
In Section
Seekers of Perl Wisdom
|
|