The Sun Also Rises

Algorithm, Mathematica, 计算机科学, C++, photography, GNU/Linux的讨论空间

  C++博客 :: 首页 :: 新随笔 :: 联系 :: 聚合  :: 管理 ::
  73 随笔 :: 6 文章 :: 169 评论 :: 0 Trackbacks
500分的题。。。
由于之前看到过chomp game,(《Game Theory》的练习里有),然后开始试图推公式之类的。。。在wiki上找到rectangle情况先手必胜的证明:

Who wins?

Chomp belongs to the category of impartial 2-player perfect information games.

It turns out that for any rectangular starting position bigger than 1 × 1 the 1st player can win. This can be shown using a strategy-stealing argument: assume that the 2nd player has a winning strategy against any initial 1st player move. Suppose then, that the 1st player takes only the bottom right hand square. By our assumption, the 2nd player has a response to this which will force victory. But if such a winning response exists, the 1st player could have played it as his first move and thus forced victory. The 2nd player therefore cannot have a winning strategy.

Computers can easily calculate winning moves for this game on two-dimensional boards of reasonable size.


很优美的证明。。。只可惜不能提供任何strategy...-_-bbbbbbbb
最后终于悟出来这题规定棋盘3*n, n<=100,所以就100*100*100的dp就行了。。-_-bbbbbbbbbb


p.s. wiki : Chomp Game


p.s. 确实觉得一知半解是一个很容易出错的情况...因为如果完全不知道思维也就没有任何限制了,曾经看到过么...感觉会有点紧张(想要赶紧搞掉的那种感觉) & 试图用记忆中的套路去做...但有时候可能没有关系(例如这个game, 先手必胜的证明并不能提供任何先手如何operate的信息...,如果继续往这个上面想就直接挂了...-_-bbbbbbb)
还有就是有可能会出现类似于"当时为什么不仔细推清楚"之类的念头...这个seems容易解决...

感觉如果是完全陌生的题想法通常容易比较open, 如果感觉这个模型熟悉一般都会试图往熟悉的模型上套...大多数情况下这样确实可以节省时间...但是如果失去了open的思维 + 熟悉的模型无法解决就orz了...


posted on 2008-02-17 04:15 FreePeter 阅读(988) 评论(4)  编辑 收藏 引用 所属分类: AlgorithmACM/ICPC

评论

# re: TCO Round1, [500], CHOMP Game... 2008-02-17 22:17 ziliang
嗯,我也是暴力DP上去的...
不过题目咋一看就像是可以SG的...真是orz了  回复  更多评论
  

# re: TCO Round1, [500], CHOMP Game... 2008-02-18 22:26 FreePeter
@ziliang
典型的想复杂了么~~~  回复  更多评论
  

# re: TCO Round1, [500], CHOMP Game... 2008-02-21 19:54 xcw
问一下topcoder srm div2 1000那个题目.
刚开始做的时候我没有特殊处理(0,x),(x,0)几个特殊点.就直接算SG.
结果不对,和别人的程序算出来的SG对比,虽然必输的时候都是0,但是其他非0的就不一样了...为什么(0,x),(x,0)的SG值不能直接写成0呢?  回复  更多评论
  

# re: TCO Round1, [500], CHOMP Game... 2008-02-22 19:08 FreePeter
@xcw
你是指SRM 384吧
我怎么记得应该是把(0, x), (x, 0), (x, x)直接写成0吧?
因为原来的游戏还是稍微要变下模型的(注意是只要把某一个棋子move to (0, 0)就胜利)。

这里有篇summary~, you may also refer to the analysis of TopCoder...
http://wtommy.yculblog.com/post.2796402.html

  回复  更多评论
  


只有注册用户登录后才能发表评论。
网站导航: 博客园   IT新闻   BlogJava   知识库   博问   管理


Creative Commons License
This site is licensed under a Creative Commons Attribution-Share Alike 2.5 China Mainland License. 本站采用创作共用版权协议, 要求署名、相同方式共享. 转载本站内容必须也遵循“署名-相同方式共享”的创作共用协议. This site is licensed under a Creative Commons Attribution-ShareAlike 2.5 License.