为啥没反应啊
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb18030">
<title>Untitled Document</title>
</head>
<body>
<script type="text/javascript">
/*
* param1 Array
* param2 Array
* return true or false
*/
function arraysSimilar(arr1, arr2){
if(arr1 instanceof Object!=true || arr2 instanceof Object!=true || arr1.length!=arr2.length){
return false;
}else{
for(i=0;i<arr1.length;i++){
var arr3=Object.prototype.toString.apply(arr1[i]);
var arr4=Object.prototype.toString.apply(arr2[i]);
}
arr3.sort();
arr4.sort();
if(arr3.toString() != arr4.toString()){
return false;
}else{
return true;
}
}
}
</script>
<script src="testData.js"></script>
</body>
</html>