[ create a new paste ] login | about

Link: http://codepad.org/HWk2SODd    [ raw code | output | fork ]

aaronla - Python, pasted on Sep 4:
1
2
3
4
5
6
7
8
9
10
# faster_maybe.py 

import time
a = [8 - (i % 17) for i in range(300000)]
sum = 0
t1 = time.time()
for i in a:
    sum = sum + i
t2 = time.time()
print t2-t1


Output:
1
0.17640709877


Create a new paste based on this one


Comments: