On 2005-06-09, Grant Edwards <[EMAIL PROTECTED]> wrote:
> On 2005-06-09, Jan Danielsson <[EMAIL PROTECTED]> wrote:
>
>> In C, I would do this:
>>
>> server.invalidUntil = time(NULL) + 5*60; // five minute delay
>
> In Python, I would do this:
>
> server.invalidUntil = time.time() + 5*60 # five minute delay
>
>> ..and the check:
>>
>> if(time(NULL) > server.invalidUtil)
>> {
>> // use server
>> }
>
> if time() > server.invalidUntil:
> # user server
Um, that should have been
if time.time() > server.invalidUntil:
# use server
>> So the whole thing very simple...
>
> Yup.
Not quite simple enough that I could get it right the first time.
--
Grant Edwards grante Yow! I need to discuss
at BUY-BACK PROVISIONS
visi.com with at least six studio
SLEAZEBALLS!!
--
http://mail.python.org/mailman/listinfo/python-list