subject

Josh and Daniella are playing a game using a bunch of coins. The players pick several coins out of a pile in turn. Each time a player is allowed to pick 1, 2 or 4 coins, and the player that gets the last coin is the winner. Assume that both players are very smart and he/she will try his/her best to work out a strategy to win the game. For example, if there are 2 coins and Daniella is the first player to pick, she will definitely pick 2 coins and win. Given the number of coins and the order of player you are required to write a program to calculate the winner of the game, and calculate how many different strategies there are for he/she to win the game.

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 11:00
In the context of the box model, what is the difference between a margin and a padding? a. a padding lies outside a box border, while a margin lies inside it. b. a padding lies inside a box border, while a margin lies outside it. c. a padding can be adjusted independently, while a margin depends on the size of its box. d. a padding depends on the size of its box, while a margin can be adjusted independently.
Answers: 3
question
Computers and Technology, 23.06.2019 12:50
Which syntax error in programming is unlikely to be highlighted by a compiler or an interpreter? a variable name misspelling a missing space a comma in place of a period a missing closing quotation mark
Answers: 1
question
Computers and Technology, 24.06.2019 13:30
In the rgb model, which color is formed by combining the constituent colors? a) black b) brown c) yellow d) white e) blue
Answers: 1
question
Computers and Technology, 25.06.2019 08:20
The process of representing data in digital form so it can be used by a digital computer is called decimal byterepresentation. - true or false
Answers: 3
You know the right answer?
Josh and Daniella are playing a game using a bunch of coins. The players pick several coins out of a...
Questions
question
Mathematics, 07.09.2020 03:01
question
Social Studies, 07.09.2020 03:01
Questions on the website: 13722362