Array-specialization of endsWith with default predicate.
const x = "beta version"; assert(x.endsWithAmong(["version", ""])); assert(x.endsWithAmong(['n', ' '])); assert(x.endsWithAmong("n ")); assert(!x.endsWithAmong(["_"])); assert(!x.endsWithAmong(['_']));
See Implementation
Array-specialization of endsWith with default predicate.