If you disregard timezones, my favourite method of calculating yesterday's date is the following:
my $yesterday = localtime; sleep( 86400 ); print "Yesterdays date is $yesterday\n";
People might complain that the runtime is a bit too long, but I'm sure one can reduce the runtime by rewriting this program in C, Haskell or Perl6.
In reply to Re^2: Date Manipulation
by Corion
in thread Date Manipulation
by SR
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |