boristane / boristane/arr-sorting
Add support for introsort
Open
enhancement
help wanted
- Dominant language
- JavaScript
- Stars
- 2
- Forks
- 0
- PR merge metrics
- No merged PRs in 30d
Description
Sorts an array using the introsort algorithm.
```js
const arr = [2, 5, 10, 5, 32, 6];
intro(arr); // [2, 5, 5, 6, 10, 32]
intro(arr, (a, b) => b - a); // [32, 10, 6, 5, 5, 2]
```
[Reference](https://en.wikipedia.org/wiki/Introsort)
**Update README.md**.
Contributor guide
Assessment
This issue has not been assessed yet.