@anonymous/

WelllitWhoppingEmulators

JavaScript

No description

fork
loading
main.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
function destroyer(arr) {
  // Remove all the values
  var arr2 = arr.slice.call(arguments);
  var arr1 = arr2.shift();
  var newArr = [];
  function a() { 
    console.log(a);
    console.log(arr2[i]);
  return a !== arr2[i];   //this compares each element of arr1 to arr2
  }  
  for (i = 0; i < arr2.length; i++) {  
    newArr = arr1.filter(a);
  }  // deletes the similarities in arr1, and applies the changes to newArr  
//  var newArr = arr.filter(function(a) {return Boolean(!a);
   //                                          });  
  return newArr;
}
destroyer([1, 2, 3, 1, 2, 3], 2, 3);
Native Browser JavaScript