in reply to Date Conversion: yyddd to yyyymmdd

As other monks have shown above, there is more than one way to do it. I like Date::Calc (especially for its good documentation and examples!), so here is a way on how to do the conversion using that module:
use Date::Calc qw(Add_Delta_Days); my $input = "11004"; # yyddd $input =~ /(\d\d)(\d\d\d)/; my ($y, $m, $d) = Add_Delta_Days("20$1",1,1, $2 -1); # based on an ex +ample in the Date::Calc-docu my $output = sprintf("%4d%02d%02d", $y, $m, $d);
HTH, Rata