文件名称:couroutine
下载
别用迅雷、360浏览器下载。
如迅雷强制弹出,可右键点击选“另存为”。
失败请重下,重下不扣分。
如迅雷强制弹出,可右键点击选“另存为”。
失败请重下,重下不扣分。
介绍说明--下载内容均来自于网络,请自行研究使用
Simple example of using python coroutines and generators to create a market simulator with:
1) A one-good market, collecting bids from the agents, which, after each trading period, updates each price, and
2) a set of agents, observing the market price at each trading period, and submitting bids back.
Such a setup would usually be achieved by the observer pattern, where each trader will subscribe to the price changes, but usage of generators and coroutines leads to more elegant code in this case.
1) A one-good market, collecting bids from the agents, which, after each trading period, updates each price, and
2) a set of agents, observing the market price at each trading period, and submitting bids back.
Such a setup would usually be achieved by the observer pattern, where each trader will subscribe to the price changes, but usage of generators and coroutines leads to more elegant code in this case.
(系统自动生成,下载前可以参看下载内容)
下载文件列表
couroutine\MarketGenerators.py
..........\__init__.py
couroutine