Tell us what’s happening:
Can somebody tell me why this doesnt work? It work for some of the requirements but not all
Your code so far
function dropElements(arr, func) {
// Drop them elements.
return arr.filter(func);
}
dropElements([1, 2, 3], function(n) {return n < 3; });
Your browser information:
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36
.
Link to the challenge:
https://learn.freecodecamp.org/javascript-algorithms-and-data-structures/intermediate-algorithm-scripting/drop-it