http://www.perlmonks.org?node_id=864968


in reply to Re^4: Determing Week Ranges between given date range?
in thread Determing Week Ranges between given date range?

Yeah, that's functionally equivalent, but I wanted to keep the two halves of the equation separate (calculating the last day of the week and calculating the number of days until the last day of the week). In mine, ($first_dow + 6) can be replaced with $last_dow.