ml-array-mode
v1.1.5
Published
Get the most repeated value in an array
Downloads
21,202
Keywords
Readme
array-mode
Get the most repeated value in an array.
Installation
$ npm install --save ml-array-mode
Usage
import mode from 'ml-array-mode';
const result = mode([1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 4, 4, 4, 4, 4]);
// 4