W3School TIY Editor
W3School 在线教程
改变方向
暗黑模式
运行代码
<!DOCTYPE html> <html> <body> <h2>JavaScript 语句</h2> <p>一行允许多条语句。</p> <p id="demo1"></p> <script> var a, b, c; a = 5; b = 6; c = a + b; document.getElementById("demo1").innerHTML = c; </script> </body> </html>