Q-Learning Nim with Python

In this post I’m going to explain a simple AI that can learn to win a game with no previous knowledge of the rules, goals, or decision process of its opponent. The Game Nim is a game where two players take turns picking up sticks from a board that contains a number of sticks. Each …