Mastering Color Water Sort Puzzle Games

Jerry An
6 min readNov 18, 2023

Are you ready to challenge your problem-solving skills with color water sort games? Let’s dive into how to approach these puzzles.

Understanding the Game

In this engaging puzzle game, the objective is to sort different colored liquids into individual test tubes until each tube contains a single color. The catch? You can only pour a liquid into another tube if it matches the topmost color, and there’s enough space.

Game State

In a real-life context, the “game state” refers to the current status or setup of a game at any given point in time. It includes the position, status, or condition of all the relevant pieces, players, or elements that are part of the game’s rules and play.

For the color water sort puzzle game, it would be the physical arrangement of the test tubes and the colored liquids within them at the start of the game or at any moment during gameplay.

It can be represented by a list of tuples, where each tuple contains a color (represented as a number) and a corresponding volume.

# Yellow: 1
# Red: 2
# Purple: 3
# Orange: 4
# Green: 5
# Light purple: 6
# Blue: 7

Here’s an example game state for the above image.



game_state = [
# Tube 1…

--

--