This week only. Pastebin PRO Accounts Christmas Special! Don't miss out!Want more features on Pastebin? Sign Up, it's FREE!
Guest

Untitled

By: a guest on Jul 29th, 2011  |  syntax: None  |  size: 0.18 KB  |  views: 47  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. >>> import timeit
  2. >>> t = timeit.Timer('"abc" + "123"')
  3. >>> t.timeit()
  4. 0.10069966993011681
  5. >>> t2 = timeit.Timer('"".join(("abc", "123"))')
  6. >>> t2.timeit()
  7. 0.44369074840517442
clone this paste RAW Paste Data