This has this which gives either true or false and in this particular case: true
const array = [1, 2, 3, 4, 5]; const even = (element) => element % 2 === 0; console.log(array.some(even));
No comments:
Post a Comment