validating row and column
validating diagonal