Skip to content
Subhajit Sahu edited this page Feb 4, 2021 · 15 revisions

Checks if any value satisfies a test. 📦 😺 🏃 📼 🌔 📜 📰 📘

Similar: some, every.


lists.some(x, [ft]);
// x:  lists
// ft: test function (v, k, x)
const lists = require('extra-lists');

var x = [['a', 'b', 'c', 'd'], [1, 2, -3, -4]];
lists.some(x, v => v > 10);
// false

lists.some(x, v => v < 0);
// true


References

Clone this wiki locally