This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ python2.7 -m timeit -n 1000000 -r 5 -v 'd=dict();d["a"]="b"' | |
raw times: 0.182 0.179 0.179 0.18 0.179 | |
1000000 loops, best of 5: 0.179 usec per loop | |
$ python2.7 -m timeit -n 1000000 -r 5 -v 'd={};d["a"]="b"' | |
raw times: 0.0863 0.0859 0.0858 0.0882 0.0877 | |
1000000 loops, best of 5: 0.0858 usec per loop | |
gokmen@rodosto % python3.3 -m timeit -n 1000000 -r 5 -v 'd=dict();d["a"]="b"' |