数组去重
2017-09-15 本文已影响0人
溺水的睫毛
var arr = [1, 5, 6, 3, 8, 9, 2, 3, 1, 4, 5, , 8, 9, 5, 6, 4, 8, 9, 1, 2, 3, 4, 5, 8]
for(var a = 0 ; a < arr.length; a++){
for(var b = a+1;b< arr.length ; b++){
if(arr[a]==arr[b]){
arr.s
}
}
}
var arr = [1, 5, 6, 3, 8, 9, 2, 3, 1, 4, 5, , 8, 9, 5, 6, 4, 8, 9, 1, 2, 3, 4, 5, 8]
for(var a = 0 ; a < arr.length; a++){
for(var b = a+1;b< arr.length ; b++){
if(arr[a]==arr[b]){
arr.s
}
}
}