I was implementing a game of TicTacToe, so I defined the set of marks $T = \{X, O, E\} $ where $E$ corresponds to no mark placed on a cell. In one part of the code I defined an operation $\circ : T \times T \rightarrow T$ such that $a \circ a = a$ and $x \circ y = E$ if $x \ne y$. This operation is used to determine whether there is a winner in a given row, column or diagonal. In other words, I can reduce a list of marks using this operation and get the winner as the result ($E$ means there is no winner). I noticed that $\langle T, \circ \rangle$ is a semilattice with zero.
In another part of the code, I defined the partial order $X \le E \le O$ (alternatively, $O \le E \le X$). I use this in the search for the best possible move in the game tree. From this order, I can define the operation $\diamond : T \times T \rightarrow T$ such that $x \diamond y = x$ if, and only if, $x \le y$. So, $\langle T, \diamond \rangle$ is a another semilattice.
Is there any deeper algebraic wisdom behind these facts or is it just a fun and irrelevant coincidence? (Disclaimer: I'm not a mathematician)