Guest User

Untitled

a guest
Sep 8th, 2011
236
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.45 KB | None | 0 0
  1. from xml.dom.minidom import parseString
  2. import copy
  3. import time
  4. dom1=parseString("<a><b/><b/><b/></a>")
  5. ini=time.time()
  6. bElement=dom1.getElementsByTagName("b")
  7. for i in xrange(0,1000):
  8.     copy.deepcopy(bElement)
  9. print "Time:",time.time()-ini
  10.  
  11. """
  12. 32bit ubuntu 11.04 virtual machine using virtual box
  13. python 2.7.1+
  14. Time: 0.305788993835
  15. pypy1.6 (with jit)
  16. Time: 1.42044305801
  17. pypy-c-1.6-svn (http://pastebin.com/FhLLNxMT)
  18. Time: 1.2382171154
  19. """
Advertisement
Add Comment
Please, Sign In to add comment