摩根2010Coding

上传人:jiups****uk12 文档编号:54878757 上传时间:2018-09-21 格式:PPT 页数:33 大小:2.23MB
返回 下载 相关 举报
摩根2010Coding_第1页
第1页 / 共33页
摩根2010Coding_第2页
第2页 / 共33页
摩根2010Coding_第3页
第3页 / 共33页
摩根2010Coding_第4页
第4页 / 共33页
摩根2010Coding_第5页
第5页 / 共33页
点击查看更多>>
资源描述

《摩根2010Coding》由会员分享,可在线阅读,更多相关《摩根2010Coding(33页珍藏版)》请在金锄头文库上搜索。

1、Morgan Stanley Coding Competition,16 Oct 2010,Welcome,Morgan Stanley Technology,What is the competition about?,Programming challenge for a group of three students in 24 hours Competing with students from other schools The winning team from each campus would be selected for the final round: The winni

2、ng team would be invited to our Shanghai HQ Final round is a competition across participating schools, the final winner would entitle to: iPads, Macbooks.,The challenge,You are responsible to run a fruit warehouse with ¥100,000 cash for one year There is only one wholesaler and one distributor you h

3、ave to interact with The wholesaler would tell you the lowest price they are willing to sell for each product, and the amount available The distributor would tell you the highest price they are willing to buy and how much they need You are competing with other warehouses to make optimal purchase and

4、 sales decisions: buy low and sell high Fruits are perishable: any inventory that is left at the end would be marked down at 10%,The game rule and format,Create a game client to communicate with the game server The game is played in rounds, each round represents a business day There are 200 rounds a

5、nd 30 products available In the beginning of the round, you would receive supply and demand message from the game server Your client needs to send back the amount and price that you wish to purchase and sell You can not sell more than what you have, and you can not buy if you dont have enough cash t

6、o complete the transaction Your team have until Sunday 9AM to develop your client, we will hold the final competition in this room,Technical details,The message format is in JSON Clients have to login to the server and all communications are done via TCP During each round, the following messages wou

7、ld be exchanged: Round start message including supply and demand Order message sent by your client to perform purchase and sell transaction Round end message indicating the successful transactions We provide some sample clients to get you started Feel free to utilize any open source libraries availa

8、ble,Technical details,Testing and development support,On demand test server available: http:/114.80.213.55:8080/codestorm/test Use your given team name and key to login Connect your client to the host port displayed Server can generate up to 8 random clients to compete against you 20 products and 10

9、0 rounds You can invite other teams to test your strategies!,Offer Matching,The minimum bid price is the same as the maximum offer price, each round minimum bid price is the least you can offer to buy from the wholesaler maximum offer price is the most you can offer to sell at to the distributor Ord

10、er are filled in alphabetical order by product you could run out of money for Zucchinis if all your bids for Apples are accepted Offers are adjusted when the market is short i.e. you bid more than is still available Offers are rejected when the player is short i.e. you offer more than you have to se

11、ll or have cash to buy or if the bid/offer does exceeds the total number of units available to buy/sell,Offer Matching,In a tie situation (two offers at the same price) the client which sent its response first will win auction does not consider the number of units bid or offered when resolving a tie

12、 Orders are settled at the end of the round For example, you have N units of a fruit at the start of round X. You cannot sell more than N units of that fruit during that round, even if your submission also includes a buy order to buy more of the same fruit. Market activity affects market prices your

13、 activity is only a small portion of the global fruit-distribution market,Offer Matching Example,Round starts,Offer Matching Example,Players receive supply and demand,Offer Matching Example,Players send offers,Sell: 2 Pear $3.00 Buy: 5 Apple $2.00 Buy: 2 Pear $3.33,Sell: 1 Pear $2.00 Buy: 2 Apple $2

14、.50 Buy: 3 Pear $3.00,Sell: 5 Apple $1.50 Buy: 5 Apple $2.00 Buy: 5 Pear $4.00,Received 1st:,Received 2nd:,Received 3rd:,Offer Matching Example,Server acknowledges offers,Sell: 2 Pear $3.00 Buy: 5 Apple $2.00 Buy: 2 Pear $3.33,Sell: 1 Pear $2.00 Buy: 2 Apple $2.50 Buy: 3 Pear $3.00,Sell: 5 Apple $1.

15、50 Buy: 5 Apple $2.00 Buy: 5 Pear $4.00,Received 1st:,Received 2nd:,Received 3rd:,Offer Matching Example,Matching begins,Sell: 2 Pear $3.00 Buy: 5 Apple $2.00 Buy: 2 Pear $3.33,Sell: 1 Pear $2.00 Buy: 2 Apple $2.50 Buy: 3 Pear $3.00,Sell: 5 Apple $1.50 Buy: 5 Apple $2.00 Buy: 5 Pear $4.00,Received 1

16、st:,Received 2nd:,Received 3rd:,Offer Matching Example,Lowest offer is best for matching demand,Sell: 2 Pear $3.00 Buy: 5 Apple $2.00 Buy: 2 Pear $3.33,Sell: 1 Pear $2.00 Buy: 2 Apple $2.50 Buy: 3 Pear $3.00,Sell: 5 Apple $1.50 Buy: 5 Apple $2.00 Buy: 5 Pear $4.00,Received 1st:,Received 2nd:,Received 3rd:,Offer Matching Example,Match best price for Apples,Sell: 2 Pear $3.00 Buy: 5 Apple $2.00 Buy: 2 Pear $3.33,

展开阅读全文
相关资源
相关搜索

当前位置:首页 > 行业资料 > 其它行业文档

电脑版 |金锄头文库版权所有
经营许可证:蜀ICP备13022795号 | 川公网安备 51140202000112号