lib/edtf/interval.rb
# call-seq:
#     interval.last     -> Date or nil
#     interval.last(n)  -> Array
#
# Returns the last date in the interval, or the last n dates.


Returns the last date in the interval, or the last n dates.
Returns the last date in the interval or the last n dates .
def last(n = 1)
      if n > 1
        (ds = Array(max)).empty? ? ds : ds.concat(ds[0].prev(n - 1))
      else
        max
      end
    end
def last ( n = 1 ) if n > 1 ( ds = Array ( max ) ) . empty? ? ds : ds . concat ( ds [ 0 ] . prev ( n - 1 ) ) else max end end
call-seq:
interval.last     -> Date or nil
interval.last(n)  -> Array
call - seq : interval . last - > Date or nil interval . last ( n ) - > Array
n