MonoidalFenwickTreeImpl<T> constructor

MonoidalFenwickTreeImpl<T>({
  1. required FenwickTreeMonoid<T> algebra,
  2. required int size,
})

Implementation

MonoidalFenwickTreeImpl({
  required final this.algebra,
  required final int size,
}) : array = List.filled(
        size + 1,
        algebra.identity(),
      );