Skip to content

sschakraborty/pi-tic-tac-toe

Repository files navigation

pi-tic-tac-toe

A tic tac toe game implementation using Minimax algorithm on wxWidgets 3.0.3 API

Apart from a disappointingly simple 2-player tic-tac-toe game that would enable two players to play against each other, calculating the next possible move would be a mathematical optimization technique that would be not- so-easy to implement.

I am going to explore the Minimax mathematical optimization technique in depth and implement the same on wxWidgets based UX to make a fully feasible tic-tac-toe game that is (almost!) impossible to defeat.

Minimax (sometimes MinMax or MM) is a decision rule used in decision theory, game theory, statistics and philosophy for minimizing the possible loss for a worst case (maximum loss) scenario. When dealing with gains, it is referred to as "maximin"— to maximize the minimum gain. Originally formulated for two-player zero-sum game theory, covering both the cases where players take alternate moves and those where they make simultaneous moves, it has also been extended to more complex games and to general decision-making in the presence of uncertainty.

Copyright 2017 Subhadra S. Chakraborty (pi)

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.