首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 网站开发 > Web前端 >

不住刷新,能刷出500W

2012-10-17 
不断刷新,能刷出500WhtmlheadtitleTest.jsp/title/headscript languagejavascript typete

不断刷新,能刷出500W

<html><head><title>Test.jsp</title></head><script language="javascript" type="text/javascript">num();function num() {var bluenum = Math.floor(Math.random() * 1000000000000) % 16 + 1;var rednum = new Array();for (i = 0; i < 6; i++) {rednum[i] = Math.floor(Math.random() * 1000000000000) % 33 + 1;c = rednum[i];for (j = 0; j < i; j++) {if (rednum[j] == c) {i--;j = 7;}}}for (i = 0; i < 6; i++) {for (j = i; j < 6; j++) {if (rednum[i] > rednum[j]) {temp = rednum[i];rednum[i] = rednum[j];rednum[j] = temp;}}}document.write("红号:");for (i = 0; i < 6; i++) {document.write(rednum[i]);document.write(" " + ",");}document.write("蓝号:" + bluenum + "</br>");}</script><body></body></html>

热点排行