pocketlang/test/benchmark/for/for.py
Thakee Nathees df93b2c1ec gc bugs fixed
- popping operands from the stack was too early -fixed
- some temproary string objects weren't pushed to the vm's temp root
  -fixed
- and some minor bug fixed
2021-05-23 23:25:04 +05:30

12 lines
187 B
Python

from time import process_time as clock
start = clock()
list = []
for i in range(10000000): list.append(i)
sum = 0
for i in list: sum += i
print(sum)
print("elapsed:", clock() - start)