W3School TIY
编辑您的代码:
<html> <body> <script type="text/javascript"> var arr = new Array(3) arr[0] = "George" arr[1] = "John" arr[2] = "Thomas" document.write(arr) document.write("<br />") document.write(arr.pop()) document.write("<br />") document.write(arr) </script> </body> </html>
查看结果: