I'm having some cross platform issues with timing loops.  It seems 
time.time is better for some computers/platforms and time.clock others, but 
it's not always clear which, so I came up with the following to try to 
determine which.


    import time

    # Determine if time.time is better than time.clock
    # The one with better resolution should be lower.
    if time.clock() - time.clock() < time.time() - time.time():
        clock = time.clock
    else:
        clock = time.time


Will this work most of the time, or is there something better?


Ron

-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to