Class: Fixnum
- Inherits:
-
Object
- Object
- Fixnum
- Defined in:
- lib/pickaxe/extensions.rb
Instance Method Summary collapse
Instance Method Details
#to_duration ⇒ Object
29 30 31 32 33 34 35 |
# File 'lib/pickaxe/extensions.rb', line 29 def to_duration s = self m = s / 60 s -= m * 60 [m, s].compact.zip(["m", "s"]).collect(&:join).join(" ") end |