This commit is contained in:
2023-12-24 23:00:20 +01:00
parent c5effd8f7f
commit a2687083e0
16 changed files with 91 additions and 38 deletions

View File

@@ -18,7 +18,7 @@
*/
export function window<T>(arr: T[], len: number): T[][] {
let result: T[][] = [];
const result: T[][] = [];
for (let i = 0; i < arr.length; i += len) {
result.push(arr.slice(i, i + len));
}