There was an error while loading. Please reload this page.
List all possible suffixes.
Alternatives: isuffixes, suffixes. Similar: randomSuffix, suffixes, hasSuffix.
function isuffixes(x, n) // x: an array // n: number of values [-1 ⇒ any]
const xarray = require('extra-array'); [...xarray.isuffixes([1, 2])]; // → [ [ 1, 2 ], [ 2 ], [] ] [...xarray.isuffixes([1, 2, 3])]; // → [ [ 1, 2, 3 ], [ 2, 3 ], [ 3 ], [] ]