Count the black squares (one line of input)