magicko555
magicko555

Reputation: 1

google sheets count array elements

Hi is there a way to count elements in array like that (im using google sheets)

enter image description here

I tried googling but didnt find anyone having the same problem

Upvotes: 0

Views: 144

Answers (2)

player0
player0

Reputation: 1

try:

=LEN(REGEXREPLACE(A1; "[^,]"; ))+1

enter image description here

for array:

=INDEX(IF(A1:A="";;LEN(REGEXREPLACE(A1:A; "[^,]"; ))+1))

Upvotes: 0

The God of Biscuits
The God of Biscuits

Reputation: 3207

=counta(split(cellref,",")) will count the number of elements in the array (where cellref is location of your array to be split).

Upvotes: 1

Related Questions