- days
- hours
- minutes
- seconds
Add timespan
examples/time/add_timespan.cr
now = Time.utc tomorrow = now + Time::Span.new(days: 1) puts now puts tomorrow puts now + 1.days puts now + 24.hours puts now + 1440.minutes puts now + 86_400.seconds
2021-06-29 14:31:14 UTC 2021-06-30 14:31:14 UTC 2021-06-30 14:31:14 UTC 2021-06-30 14:31:14 UTC 2021-06-30 14:31:14 UTC 2021-06-30 14:31:14 UTC
- See these methods at Int