combineN method

  1. @override
T combineN(
  1. T a,
  2. int n
)
override

Return a appended to itself n times. If n is negative, then this returns inverse(a) appended to itself n times.

Implementation

@override
T combineN(T a, int n) {
  if (n > 0) {
    return _repeatedCombineN(a, n);
  } else if (n == 0) {
    return empty;
  }

  return _repeatedCombineN(inverse(a), -n);
}