count

inline fun <Type> GdxArray<Type>.count(predicate: (Type) -> Boolean): Int

Return

the number of elements matching the predicate. Zero for an empty array. Does not use GdxArray.iterator, so it does not allocate and can be safely nested.