for (
                        l = line.indexOf(i);
                        l < line.length;
                        // if the cell is of the same type,
                        // increment the number of consecutive cells