Files
ValueScript/inputs/passing/quickSort10k.ts
2023-06-23 10:18:06 +10:00

18 lines
353 B
TypeScript

//! bench()
import quickSort from "./helpers/quickSort.ts";
import randish from "./helpers/randish.ts";
import Range from "./helpers/Range.ts";
export default function main() {
let nums = [
...Range.from(randish())
.map((x) => Math.floor(8_000 * x))
.limit(10_000),
];
nums = quickSort(nums, (a, b) => a - b);
return nums;
}