On 8/24/10 5:44 PM, Dr. David Kirkby wrote:
I'd like to find the number of days between two dates - is there any
simple way to do this in Sage.

I'm sure python's datetime module can help:

http://docs.python.org/library/datetime.html

See the example "Example of counting days to an event"


The reason for wanting this is quite funny, but I thought I'd use it to
plug Sage!

Our car got damaged by a pothole. We made a claim to the council. We
finally receiving a letter from their legal department denying
responsibility.

Their defense is they have determined the road needs to be checked once
per month.. They then provided a list of the dates the road was checked
prior to the damage to our car

5th Jan 2010
3rd Dec 2009
2nd Nov 2009

Our car got damaged on the 16th Feb - clearly more than a month after
the last inspection date on the 5th Jan.

I was thinking of suggesting they use Sage to find out the number of
days between two dates, and so would realise that there is more than a
month between 5th Jan and the 16th Feb!

A calendar sounds like it might make your point better, though a reasonable argument would be that since they only need to check it "once per month", checking it once in Jan and once in Feb would be enough.



How stupid can the council's legal department be to send a letter like
this?


I'm afraid Sage probably can't help with that.

Jason

--
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to 
sage-support+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org

Reply via email to