我换成BUTTON 哪里出错了 运行不了
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Array对象 </title>
<script type="text/javascript">
function sortNum(a,b) {
var myarr = new Array("80","16","50","6","100","1");
return b - a;
var soult = myarr.sort(sortNum);
}
document.getElementById("demo").innerHTML=soult;
</script>
</head>
<body>
<button onclick="sortNum(a,b)">点我对函数排序</button>
<p id="demo">80,16,50,6,100,1</p>
</body>
</html>