How to count items which contains sth in primitive array

how to count items which contains sth in primitive array?
I have this type of primitive array:

And i want to sum/count items like:
Klap-2 = 2
T-pap = 4
etc.

i do it like that, but it doesnt work:

{{lenght(contains(Array_for_counting; "Klap-2"))}})