Questions tagged [nim-game]

Nim is a two-player strategy game. Each turn, the player chooses a heap and removes various items from it. When all heaps are empty there is no possible move, and the player loses.

Use this tag for questions that about algorithms and other programming problems specifically related to playing the Nim strategy game. Do not use this tag for games written in the (formerly known as "Nimrod") programming language.

External links

17 questions
-1
votes
1 answer

why isn't my code going past "how many tokens would you like to take"? nim game python 3

here's the code and i have ran out of ideas. i've tried changing the indenting, but it didn't work either. the purpose of the nim game is: "a player sets up 2 piles of blocks, the second player chooses whether to go first or second, they each take…
-2
votes
3 answers

Java operations on an array of integers

I'm considering an array of integers in Java. The array size is determined at the start of the program by the user My idea idea is that - given any position for the corresponding binary values - the result should show 1 for any bit where only one of…
Ellis Thompson
  • 408
  • 6
  • 18
1
2