<script type="text/javascript"> var infos=[ ['小A','女',21,'大一'], ['小B','男',23,'大三'], ['小E','女',22,'大四'], ['小F','男',21,'大一'],['小G','女',22,'大二'], ['小H','女',20,'大三'], ['小I','女',20,'大一'], ['小J','男',20,'大三'] ];for(var i=0;i<10;i++){if(infos[i][3]=='大一'){ document.write(infos[i][0]+"<br/>"); }}
//创建数组
var arr = ['*', '##', "***", "&&", "****", "##*"];
arr[7] = "**";
//显示数组长度
alert(arr.length);
//将数组内容输出,完成达到的效果。
document.write(arr[0] + "<br>");
document.write(arr[7] + "<br>");
document.write(arr[2] + "<br>");
document.write(arr[4] + "<br>");
var arr = ['*', '##', "***", "&&", "****", "##*"];
arr[7] = "**";
//显示数组长度
alert(arr.length);
//将数组内容输出,完成达到的效果。
document.write(arr[0] + "<br>");
document.write(arr[7] + "<br>");
document.write(arr[2] + "<br>");
document.write(arr[4] + "<br>");
for (i = 0;i <= infos.length ;i++){
for (j = 0; j <= infos[i].length; i++){
if (infos[i][3] === "大一" && infos[i][1] === "女"){
document.write(infos[i] + "<br/>");
}
}
}
for (j = 0; j <= infos[i].length; i++){
if (infos[i][3] === "大一" && infos[i][1] === "女"){
document.write(infos[i] + "<br/>");
}
}
}