I have the following code:
nowtime = datetime.datetime.now()
newTime = time.strptime(myTimestring, '%Y-%m-%d %H:%M:%S')
if(newTime > nowTime):
#do some stuff
Of course, my comparison fails with a TypeError, "can't compare datetime.datetime to tuple.". Note that I am using an older version of Python that doesn't have datetime.strptime(). How can I get this comparison to work?