method week
1 | role Dateish |
1.1 | (Dateish) method week |
Documentation for method week
assembled from the following types:
role Dateish
From Dateish
(Dateish) method week
Defined as:
method week()
Returns a list of two integers: the year, and the week number. This is because at the start or end of a year, the week may actually belong to the other year.
my (, ) = Date.new("2014-12-31").week;say ; # OUTPUT: «2015»say ; # OUTPUT: «1»say Date.new('2015-01-31').week; # OUTPUT: «(2015 5)»