Refactor checkRows, checkColumns and checkDiagonals functions
Refactor checkRows, checkColumns and checkDiagonals functions

Add helper functions allElementsInRowAreSame, isCellEmpty etc.
and helper variables to simplify boolean expressions

Lingvokot/Tic-Tac-Toe-React,Lingvokot/Tic-Tac-Toe-React,Lingvokot/Tic-Tac-Toe-React