>>>> import datetime
s = '09:35:23'
datetime.datetime.strptime(s, '%H:%M:%S')
datetime.datetime(1900, 1, 1, 9, 35, 23)

Can you figure out how to proceed from there?
In case she doesn't know:

import datetime as dt
start="09:35:23"
end="10:23:00"

start_dt = dt.datetime.strptime(start, '%H:%M:%S')

end_dt = dt.datetime.strptime(end, '%H:%M:%S')

diff.seconds/60

_______________________________________________
Tutor maillist  -  Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor

Reply via email to