[EMAIL PROTECTED] (David M. Cooke) wrote:
> > It seems kind of surprising that I can't time functions. Am I just not
> > seeing something obvious?
>
> Like the documentation for Timer? :-)
>
> class Timer([stmt='pass' [, setup='pass' [, timer=]]])
>
> You can't use statements defined elsewhe
Roy Smith <[EMAIL PROTECTED]> writes:
> I'm playing with the timeit module, and can't figure out how to time a
> function call. I tried:
>
> def foo ():
> x = 4
> return x
>
> t = timeit.Timer ("foo()")
> print t.timeit()
>
> and quickly figured out that the environment the timed code ru