Heavy Metal Tic Tac Toe Tomek, Solution to Google Code Jam Challenge