/** * Call a callback x times */ export declare function times(n: number, cb: (k: number) => T): T[]; /** * Update an item in an array without mutating the array */ export declare function setAtIndex(arr: T, index: number | number[], newValue: unknown): T; /** * Get a value inside an array */ export declare function getAtIndex(arr: unknown, indexes: number[]): unknown; export declare function resizeArray(array: unknown, newLength: number, defaultValue?: T): T[]; /** * Return the first non-null/undefined value of an array */ export declare function firstValueItem(items: T | T[]): T | undefined; /** * Return a list of partial array * * Example : * - subArray([1, 2, 3]) // [[1], [1, 2], [1, 2, 3]] */ export declare function subArrays(items: T[] | T): T[][]; /** * Calculates the depth of an array */ export declare function depth(arr: unknown, base?: number): number; /** * Find the longest array from a list of arrays */ export declare function findLongest(arr: T[]): T;