I have a script that gets current date using localtime and previous day using localtime - 60 * 60 * 24. This forum was very helpful in the commands to do this.
My question is will I get the correct previous day on January 1? What about March 1 in leap years. Not being that familiar with Perl, I'm not sure if perl somehow accomodates this or if there is additional code I need to get the correct previous day in these two situations.
Any help or direction would be appreciated.
My question is will I get the correct previous day on January 1? What about March 1 in leap years. Not being that familiar with Perl, I'm not sure if perl somehow accomodates this or if there is additional code I need to get the correct previous day in these two situations.
Any help or direction would be appreciated.