Member-only story

Hex - Creating Intelligent Adversaries (Part 1: Minimax α-β Pruning)

Demystifying AI Game Opponents

--

In today’s article, I am going to show you how to create intelligent opponents with Alpha-Beta Minimax algorithm. We will create an agent that can successfully compete with humans in the classic Hex game. After the end of this article, you will be able to create adversarial search agents that can competitively play zero-sum and perfect information games.

Example gameplay

Table of Contents

About Hex

History

Game of Hex was invented by John Nash in the 1940s. John Nash was an American mathematician who made fundamental contributions to game theory, differential geometry, and the study of partial differential equations. While he wasn’t focused on economics per se, his findings were widely used there and he ultimately received a Nobel Memorial Prize in Economic Sciences.

John Forbes Nash

If you haven’t seen ‘A Beautiful Mind’, I strongly recommend you to watch this remarkable movie about his life.

Meanwhile, take a look at these two deleted scenes (no spoilers) about the invention of Hex.

Rules

Hex is a strategy board game for two players played on a hexagonal

--

--

No responses yet

Write a response