Logic for basic win detection.
Implemented double click behaviour to auto clear cells.