
博弈
protecteyesight
我向往天空的湛蓝和一望无际。保护视力,只为看到更远的天空。
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
HDU 3032 Nim or not Nim?
Nim is a two-player mathematic game of strategy in which players take turns removing objects from distinct heaps. On each turn, a player must remove at least one object, and may remove any number of o原创 2016-12-14 18:18:40 · 273 阅读 · 0 评论 -
HDU - 2516 取石子游戏
1堆石子有n个,两人轮流取.先取者第1次可以取任意多个,但不能全部取完.以后每次取的石子数不能超过上次取子数的2倍。取完者胜.先取者负输出"Second win".先取者胜输出"First win". Input输入有多组.每组第1行是2Output先取者负输出"Second win". 先取者胜输出"First win". 参看Sample Output. Sam原创 2016-12-08 16:11:16 · 323 阅读 · 0 评论 -
A - Matrix Game(nim 博弈)LightOJ 1247
Given an m x n matrix, where m denotes the number of rows and n denotes the number of columns and in each cell a pile of stones is given. For example, let there be a 2 x 3 matrix, and the piles are原创 2016-12-05 18:17:05 · 258 阅读 · 0 评论 -
B - Misere Nim 变式nim(LightOJ 1253)
Alice and Bob are playing game of Misère Nim. Misère Nim is a game playing on k piles of stones, each pile containing one or more stones. The players alternate turns and in each turn a player can sele原创 2016-12-05 18:28:55 · 393 阅读 · 0 评论 -
博弈的总结
取石子问题有一种很有意思的游戏,就是有物体若干堆,可以是火柴棍或是围棋子等等均可。两个人轮流从堆中取物体若干,规定最后取光物体者取胜。这是我国民间很古老的一个游戏,别看这游戏极其简单,却蕴含着深刻的数学原理。下面我们来分析一下要如何才能够取胜。(一)巴什博奕(Bash Game):只有一堆n个物品,两个人轮流从这堆物品中取物,规定每次至少取一个,最多取m个。最后取光者得胜。转载 2017-03-28 16:29:44 · 207 阅读 · 0 评论 -
HDU 6139 Galaxy at War(坑题+阶梯博弈)
传送门题意:两个人玩游戏(博弈),有一个n*m大小的方阵,有k个点,每个点上有数量不定的水晶,两人轮流移动,每次移动可以把一个位置上任意数量(大于0) 的水晶移动到这个位置的上一格或者右一格,不能移动到边界外,轮到谁没有可操作的水晶的话谁就输。整个方阵上有两种特殊的位置,数量不定。一种叫 Meditations ,这种位置上的水晶挪动的时候,假如你想往上移动m个,那么这个特殊位原创 2017-08-30 16:47:03 · 340 阅读 · 0 评论 -
HDU 5973 威佐夫博弈+JAVA高精度
Two people face two piles of stones and make a game. They take turns to take stones. As game rules, there are two different methods of taking stones: One scheme is that you can take any number of ston原创 2017-06-08 21:10:44 · 468 阅读 · 0 评论