This file contains 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
import sys | |
import time | |
sys.setrecursionlimit(1200) | |
def g1(depth): | |
if depth > 0: | |
it = g1(depth-1) | |
yield next(it) | |
else: |
This file contains 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
import asyncio | |
END = b'Bye-bye!\n' | |
@asyncio.coroutine | |
def echo_client(): | |
reader, writer = yield from asyncio.open_connection('localhost', 8000) | |
writer.write(b'Hello, world\n') | |
writer.write(b'What a fine day it is.\n') | |
writer.write(END) |
NewerOlder