标签:i++ span ++ amp == push 数组 doc status
var arr = [1,1,2,2,3,3,4,4,5,5,6,6];
var arr2=[];
for(var i = 0;i<arr.length;i++){
var status = 0;
for(var j = 0;j < arr2.length;j++){
if(arr[i]==arr2[j]){
status = 1;
break;
}
}
if(status == 0){
arr2.push(arr[i]);
}
}
for(var x in arr2){
document.write(arr2[x] + " ");
}
标签:i++ span ++ amp == push 数组 doc status
原文地址:http://www.cnblogs.com/yangchuanqi/p/7588771.html