check if the sum of row is 1