Thursday, October 3, 2013

time THIS

>>> timeit.timeit("s.recv(1, socket.MSG_PEEK", '''
... import socket
... s = socket.create_connection( ("google.com", 80) )
... s.send("blah blah\\n\\r\\n\\r\\n\\r\\n\\r\\n\\rblahblah blah"
... ''')
Traceback (most recent call last):
  File "<stdin>", line 5, in <module>
  File "C:\Python27\lib\timeit.py", line 230, in timeit
    return Timer(stmt, setup, timer).timeit(number)
  File "C:\Python27\lib\timeit.py", line 136, in __init__
    code = compile(src, dummy_src_name, "exec")
  File "<timeit-src>", line 11
    _t1 = _timer()

SyntaxError: invalid syntax

2 comments:

  1. What are you trying to say? You're missing one ) in the first line.

    ReplyDelete
  2. Right when you purchase a (got from) The Wild smell you will get a voucher code giving you half off.
    By: https://www.voucherpro.co.uk/

    ReplyDelete