I have two times, a start and a stop time, in the format of 10:33:26 (HH:MM:SS). I need the difference between the two times. I\'ve been looking through documentation for
This site says to try:
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 = (end_dt - start_dt) diff.seconds/60
This forum uses time.mktime()