Last Friday of each month: Difference between revisions
→{{header|Ruby}}: Replaced active_support version, date class recently got its own convenience methods.
m (→{{header|REXX}}: changed/added comments and whitespace, changed indentations, moved documentation for the lastDOW function to a separate window.) |
(→{{header|Ruby}}: Replaced active_support version, date class recently got its own convenience methods.) |
||
Line 2,133:
</pre>
Or get the last day of the month and go to the previous day until it's friday.
▲<lang ruby>require 'activesupport'
def last_friday(year, month)
d = Date.new(year, month, -1)
d
end
</lang>
=={{header|Run BASIC}}==
|