SOlution for tic tac toe tomek problem