Book Image

Artificial Intelligence with Python

Book Image

Artificial Intelligence with Python

Overview of this book

Artificial Intelligence is becoming increasingly relevant in the modern world. By harnessing the power of algorithms, you can create apps which intelligently interact with the world around you, building intelligent recommender systems, automatic speech recognition systems and more. Starting with AI basics you'll move on to learn how to develop building blocks using data mining techniques. Discover how to make informed decisions about which algorithms to use, and how to apply them to real-world scenarios. This practical book covers a range of topics including predictive analytics and deep learning.
Table of Contents (23 chapters)
Artificial Intelligence with Python
Credits
About the Author
About the Reviewer
www.PacktPub.com
Customer Feedback
Preface

Chapter 9. Building Games With Artificial Intelligence

In this chapter, we are going to learn how to build games with Artificial Intelligence. We will learn how to use search algorithms to effectively come up with strategies to win the games. We will then use these algorithms to build intelligent bots for different games.

By the end of this chapter, you will understand the following concepts:

  • Using search algorithms in games

  • Combinatorial search

  • Minimax algorithm

  • Alpha-Beta pruning

  • Negamax algorithm

  • Building a bot to play Last Coin Standing

  • Building a bot to play Tic Tac Toe

  • Building two bots to play Connect Four against each other

  • Building two bots to play Hexapawn against each other