Computers play chess through a combination of brute force calculations and heuristic algorithms. They analyze potential moves by searching through numerous possible game paths, but this exhaustive approach can be time-consuming. To optimize performance, programmers implement heuristics that help the computer prioritize certain moves and eliminate less promising options, allowing for quicker decision-making. This method enables computers to simulate strategic thinking without possessing true intelligence. Resources such as interactive applets illustrate how computers evaluate moves in real-time, showcasing the underlying mechanics of chess algorithms.