clean up whitespace and newlines
fix incorrect condition for detecting winning diagonals