in reply to Last month's number with Time::Piece
It's an object, you can use the method: mon()
print $lastmonth->mon, "\n"; print "ref: ", ref $lastmonth, "\n"; print "one: ", $t->add_months(-1)->mon, "\n"; # all together
Result:
Update: added ref() and example for clarification.11 ref: Time::Piece one: 11
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Last month's number with Time::Piece
by Anonymous Monk on Dec 04, 2014 at 18:51 UTC | |
|
Re^2: Last month's number with Time::Piece
by Anonymous Monk on Dec 04, 2014 at 19:04 UTC | |
by Anonymous Monk on Dec 05, 2014 at 14:20 UTC |