demos enhanced during workshop at Garoa

This commit is contained in:
Luciano Ramalho
2015-01-19 23:27:17 -02:00
parent fe0db0fa7b
commit c1e50e4477
6 changed files with 68 additions and 14 deletions

View File

@@ -2,11 +2,9 @@ import asyncio
@asyncio.coroutine
def show_remaining():
remaining = 5
while remaining:
for remaining in range(5, 0, -1):
print('Remaining: ', remaining)
yield from asyncio.sleep(1)
remaining -= 1
def main():
loop = asyncio.get_event_loop()