Reputation: 8561
I have the code as following
var ar:Array = ["Joe","Bob","Curl","Curl"];
var distinctData = ar.filter(function(itm, i){
return ar.indexOf(itm)== i;
});
The question is how can I get the parent array ar inside the filter function? I tried this keyword but it wasn't working.
Upvotes: 0
Views: 37