length method

int length()

Implementation

int length() => arr.map(getCount).fold(0, (a, b) => a + b);