# L-37 MCS 275 Wed 16 Apr 2008 : time_sin.py

# With the timeit module we see the difference in
# efficiency between math.sin and imported sin.

import timeit
t = timeit.Timer('sin(1.2)', setup='from math import sin')
s = t.timeit(100000000)
print '%.2f seconds ' % s
t = timeit.Timer('math.sin(1.2)', setup='import math')
s = t.timeit(100000000)
print '%.2f seconds ' % s
