Browse Source

Coroutines

pull/86/head
Jure Šorn 3 years ago
parent
commit
fed3afa6ae
2 changed files with 4 additions and 2 deletions
  1. 3
      README.md
  2. 3
      index.html

3
README.md

@ -2319,7 +2319,8 @@ async def view(state, screen):
screen.addstr(p.y, p.x, str(id_)) screen.addstr(p.y, p.x, str(id_))
await asyncio.sleep(0.01) await asyncio.sleep(0.01)
curses.wrapper(main)
if __name__ == '__main__':
curses.wrapper(main)
``` ```
<br> <br>

3
index.html

@ -2042,7 +2042,8 @@ D = enum.Enum(<span class="hljs-string">'D'</span>, <span class="hljs-string">'n
screen.addstr(p.y, p.x, str(id_)) screen.addstr(p.y, p.x, str(id_))
<span class="hljs-keyword">await</span> asyncio.sleep(<span class="hljs-number">0.01</span>) <span class="hljs-keyword">await</span> asyncio.sleep(<span class="hljs-number">0.01</span>)
curses.wrapper(main)
<span class="hljs-keyword">if</span> __name__ == <span class="hljs-string">'__main__'</span>:
curses.wrapper(main)
</code></pre></div></div> </code></pre></div></div>

Loading…
Cancel
Save