/** * Counts the number of elements in an array that satisfy a given predicate. */ export declare function count(array: T[], predicate: (value: T) => boolean): number; export declare function findInsertionIndexInSortedArray(array: T[], value: T, isBeforeFunction: (a: T, b: T) => boolean): number; /** * Returns the maximum element in the array according to the given sort callback. * @param arr - The array to search for the maximum element. * @param compare - The sort callback to use for comparing elements. * @returns The maximum element in the array according to the given sort callback. */ export declare function max(arr: T[], compare: (a: T, b: T) => number): T | undefined; export declare function filterMap(array: T[], map: (t: T) => K | undefined | null): K[]; /** * Behaves just like `Math.min`, so it will return Infinity for an empty array. */ export declare function min(array: number[]): number; /** * * Last batch may not match batch size. */ export declare function batchArrayElements(array: T[], batchSize: number): Iterable; //# sourceMappingURL=arrays.d.ts.map