首页 > 代码库 > 这样就算会了PHP么?-7

这样就算会了PHP么?-7

循环之类的例子

<script language="javascript">    function calculate(a, b) {            return a * b;        }    document.write(calculate(15, 15));    var i = 30;    while (i > 0) {        document.write("-" + i);        i--;    }    for (i=1; i<=9; i++) {        document.write(i+"*"+i+"="+i*i+"&nbsp;&nbsp;");    }</script><input type="submit" name="Submit" value="http://www.mamicode.com/Click Here" onClick="javascript:alert(‘You click this button.‘)">

这样就算会了PHP么?-7