英语翻译This assignment involves two related games.In each game

英语翻译
This assignment involves two related games.In each game the two players alternately
name dates.The winner is the player who names 31st December and the starting date
is 1st January.
Each of the two games use a different rule for the dates the player is allowed to name.
For each game.
1.Devise a winning strategy,stating which player should win.State also if it
depends on whether the year is a leap year or not.
2.Write a pseudocode algorithm for optimum play.
The games are.
a.(Easy) A player can name the 1st of the next month or increase the day of
the month by an arbitrary amount.(For example,the first player begins by
naming 1st February or any date in January other than the 1st).
b.(Harder) A player can name the first of the next month or the next day of
the current month.(For example,the first player begins by naming 1st
February or 2nd January).
Hint:Look for patterns.Begin by looking at December dates.
初吻我不能忘 1年前 已收到1个回答 举报

四川哈哈 幼苗

共回答了22个问题采纳率:100% 举报

人工翻译.貌似是要编程?
这个作业包括两个相关的游戏.这两名玩家在游戏里交变地说日期.赢家是说出十二月三十一日日期的人.初始日期是是1月1日.
每个游戏中使用一个不同的对于该玩家允许说的日期的规则.
为每个游戏:
1.设计一种取胜战略,并告知哪位玩家会赢.并告知这是否取决于这一年是闰年.
2.为最佳玩法编写伪代码算法.
两个游戏是.
1.(容易)一个玩家名字在下个月1日或按自定的数量增加那个月的天数.(例如,第一个开始玩游戏的人以2月1日开始或在1月1日以外的任何日期).
2.(更难)一个玩家说第一个月内或该月第二天.(例如,第一个开始玩游戏的人以二月1日或于1月2日).
提示:寻找当中的模式.首先看12月日期.

1年前

10
可能相似的问题
Copyright © 2024 YULUCN.COM - 雨露学习互助 - 16 q. 1.112 s. - webmaster@yulucn.com