Two players play a game with two piles of stones. The players alternately take stones from one or both piles, subject to:
the total number of stones taken is equal to the size of the smallest pile before the move;
the move cannot take all the stones from a pile.
The player that is unable to move loses.
For example, if the piles are of sizes 3 and 5 then there are three possible moves.
Let
You are given
Find
两位玩家用两堆石子玩游戏,两人须在遵守如下规则的同时,轮流从一个石堆或者两个石堆中取石子:
玩家本轮取走的石子总数需等于该轮开始前,含有较少石子的石堆中的石子数。
不能把其中任何一个石堆取空。
首先无法操作的玩家落败。
例如,倘若初始时两个石堆各含 3、5 枚石子,那么此时先手有三种可行操作:
记
已知
求
点 这个链接 回到源站。
点 这个链接 回到详细版题目目录。