<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>二维数组</title>
<script type="text/javascript">
var myarr=new Array();
for(var i=0;i<3;i++)
{
myarr[i]=new Array();
for(var j=0;j<5;j++)
{
myarr[i][j]=i*j;
document.write("myarr["+i+"]["+j+"]的值:"+myarr[i][j]+"<br>");
}
}
</script>
</head>
<body>
</body>
</html>
aaa
aaa
aaa
"myarr["+i+"]["+j+"]的值:" 我明白了,是因为"myarr[" 是一组,"]["是一组,"]的值:"是一组,这样i,j,才能以数字形式显示出来