From: "Xavier R." Date: 2013-02-23T04:43:23+09:00 Subject: Re: Difference of 2 dates interms of years. Matt Mongeau wrote in post #1098484: > Post some things you've tried. I tried the below : def calculate_difference minutes = (Date.parse("2009-06-20") - Date.today).to_i / 60 days = minutes / (24*60) minutes -= days * 24*60 hours = minutes / 60 minutes -= hours * 60 "#{days}d#{hours}h#{minutes}m" end which is not the one - I am looking for. :) -- Posted via http://www.ruby-forum.com/.