Tell us what’s happening:
I just have a quick question about this problem. I’m a bit confused as to how you should go about solving the problem when the arguments aren’t defined as parameters going into the function. Or I think I’m confused what the difference between an argument and a parameter is. like the function we are writing looks like it only takes in an array so how do we account for the other arguments being passed in. any clarification would help!
Your code so far
function destroyer(arr) {
console.log(arguments)
return arr;
}
destroyer([1, 2, 3, 1, 2, 3], 2, 3);
Your browser information:
User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.141 Safari/537.36
.
Challenge: Seek and Destroy
Link to the challenge: