链接:https:
来源:牛客网
var resArr = [];
var flag =
true;
for(
var i=
0;i<
this.length;i++){
if(resArr.indexOf(
this[i]) == -
1){
if(
this[i] !=
this[i]){
if(flag){
resArr.push(
this[i]);
flag =
false;
}
}
else{
resArr.push(
this[i]);
}
}
}
return resArr;
转载请注明原文地址: https://www.6miu.com/read-2628256.html