Get help on our basic JavaScript and Algorithms Challenges. If you are posting code that is large use Gist - https://gist.github.com/ paste the link here.
thecodingaviator on master
remove A (#31157) (compare)
@Zaluth soooo applying that above example to ur code.. internally its doing
function filter(value) {
return value === join;
}
[1, 2, 3, 1, 2, 3].filter(filter);
return 1 === "2, 3"
return 2 === "2, 3"
etc.. on each iteration
and since that comparation return false.. it filter everything out returning a empty array
:star2: 4929 | @sjames1958gm |http://www.freecodecamp.com/sjames1958gm
:star2: 4930 | @sjames1958gm |http://www.freecodecamp.com/sjames1958gm
var me = "hello";
var text = "hello world";
var answer = text.replace(me);
:cookie: 495 | @jluboff |http://www.freecodecamp.com/jluboff