JS案例:比较两个数的大小
来自CloudWiki
<!doctype html> <html> <head> <meta charset="utf-8"> <title>比较两个数的大小示例</title> </head><body> <script type="text/javascript"> var score=80; document.write("score变量的值为:"+score+"<br>"); document.write("score>=70:"+(score>=70)+"<br>"); document.write("score<70:"+(score<70)+"<br>"); document.write("score!=70:"+(score!=70)+"<br>"); document.write("score>70:"+(score>70)+"<br>"); </script> </body></html>