Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Python Dates and Times in Python (2014) Dates and Times Timedelta Minute

Stage 1 dates and times challenge question

When I return the arguments entered into the function 'minutes' I see the two datetimes were taken about a minute apart from each other. So what do you mean by 'minutes between them'? I don't understand how the answer is 7...

minutes.py
def minutes(d1, d2):

  return d1, d2

2 Answers

i think when you take away two dates, you get a time delta.. which returns difference in days/ seconds & microseconds.. (not sure if you get minute if not you convert seconds to minutes and return that)

Thx. That's correct. I got it.