From the course: AI Algorithms for Gaming
Unlock the full course today
Join today to access over 24,700 courses taught by industry experts.
Time complexity of chess - Python Tutorial
From the course: AI Algorithms for Gaming
Time complexity of chess
- [Instructor] Now, how about chess? Well, chess is a very much more complicated game than Tic-tac-toe, and certainly not a solved game. Let me give you an idea of the complexity of chess. Consider a game that ends after 40 pairs of moves, 40 for white and 40 for black. A pretty estimate is 10 to the 40 possible games. So how long would this take to compute? This is where the fun begins. Imagine a computer that is capable of processing a whole game of chess in one nanosecond. By game, I mean a state in the search tree, a chessboard. This is very optimistic because today a computer may be expected to perform a single operation in one nanosecond. An operation like an addition or a multiplication, not checking all 64 squares in a chess game, but let's dream. So in this computer, producing one move would take 10 to the 40 nanoseconds that's about 300 times 10 to the 21 years. Okay, let's dream some more. Your computer…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
Some history as motivation3m 46s
-
Different types of games2m 17s
-
(Locked)
Tree-based decision-making2m 28s
-
(Locked)
Time complexity of brute force approaches2m 56s
-
(Locked)
Time complexity of chess2m 31s
-
The cat trap game3m 36s
-
(Locked)
The Python setting for the cat trap3m 51s
-
(Locked)
Code example: A random cat5m
-
-
-
-
-
-