remove-min-max

Remove the minimum and the maximum from an array of numbers

Usage no npm install needed!

<script type="module">
  import removeMinMax from 'https://cdn.skypack.dev/remove-min-max';
</script>

README

remove-min-max

Remove the minimum and the maximum from an array of numbers

Build Status

js-semistandard-style

Install

$ npm install --save remove-min-max

Usage

var removeMinMax = require('remove-min-max');

removeMinMax([1, 2, 3, 5, 6, 9, 4, 7, 8]);
//=> [2, 3, 4, 5, 6, 7, 8]

API

removeMinMax(input)

input

Required
Type: Array

Array of numbers from which to remove minimum and maximum

This module will return an array sorted in ascending order

Note: v1.0.0 of this module used to mutate the supplied argument. v2.0.0 onwards, that doesn't happen. i.e. the supplied argument is NOT mutated

License

MIT © Siddharth Kannan