On 04/09/11 04:29, Cory Teshera-Sterne wrote:
> Hi all,
> 
> I have a small(ish) Python program, and I need to be able to log the
> running time. This isn't something I've ever really encountered, and
> I've been led to believe it can be a little hairy. Are there any
> Python-specific approaches to this? I found the "timeit" module, but
> that doesn't seem to be quite what I'm looking for.
> 

import cProfile
...
def main():
    ...

cProfile.run('main()')

_______________________________________________
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor

Reply via email to