Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

JavaScript Array filter()

const numbers = [45, 4, 9, 16, 25];
const over18 = numbers.filter(myFunction);

function myFunction(value, index, array) {
  return value > 18;
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #JavaScript #Array
ADD COMMENT
Topic
Name
7+6 =