How do I find the week-of-the-year/day-of-the-year?

The day of the year is in the array returned by localtime() (see perlfunc/"localtime"):

    $day_of_year = (localtime(time()))[7];

Back to perlfaq4