Hi…
I need to know the ruby code to increement the date automatically day by
day
A date object will let you add one to it.
irb(main):001:0> Date.today.to_s
=> “2015-01-22”
irb(main):002:0> (Date.today + 1).to_s
=> “2015-01-23”
irb(main):003:0>
Hi…
I need to know the ruby code to increement the date automatically day by
day
A date object will let you add one to it.
irb(main):001:0> Date.today.to_s
=> “2015-01-22”
irb(main):002:0> (Date.today + 1).to_s
=> “2015-01-23”
irb(main):003:0>
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.
Sponsor our Newsletter | Privacy Policy | Terms of Service | Remote Ruby Jobs