Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

Even numbers in an array

const evenNumbers = (array, number) => array.filter(item => item % 2 === 0).slice(-number);
 
PREVIOUS NEXT
Tagged: #Even #numbers #array
ADD COMMENT
Topic
Name
7+5 =