Help with python code!

Chris Angelico rosuav at gmail.com
Sun Mar 31 18:04:48 EDT 2013


On Mon, Apr 1, 2013 at 9:02 AM, Mark Lawrence <breamoreboy at yahoo.co.uk> wrote:
> On 31/03/2013 22:21, Chris Angelico wrote:
>>>
>>>        sue = time.mktime(
>>>          (int(m.group(7)), int(months[m.group(2)]), int(m.group(3)),
>>>            int(m.group(4)), int(m.group(5)), int(m.group(6)),
>>>            int(days[m.group(1)]), 0, 0)
>>>          )
>>>          expire_time = (sue ­ current_time)/60/60/24
>>
>>
>> Here's a likely problem. There's supposed to be an operator - probably
>> a plus sign - between sue and current_time.
>>
>
> There is actually a minus sign there which showed up when I pasted the code
> into the Eclipse/Pydev editor.  That sadly doesn't fix the problem with the
> call to mktime, 12 open round brackets to 14 close if I've counted
> correctly.

Oh, of course, since sue comes from mktime. But yeah, definitely needs
an operator there.

ChrisA



More information about the Python-list mailing list