Sorry if this is not what you want, but at least for the first part of the question, you could probably do it like this?
>>> import datetime >>> datetime.datetime.strptime(date + ' ' + hour + ':' + minutes + ':' + seconds, '%m/%d/%Y %H:%M:%S') datetime.datetime(2009, 11, 28, 23, 59)
meder omuraliev
source share