zig.com Result Size: 625 x 565
x
 
<!DOCTYPE html>
<html>
<body>
<h1>JavaScript Arrays</h1>
<h2>The concat() Method</h2>
<p>The concat() method merges (concatenates) arrays:</p>
<p id="demo"></p>
<script>
  const array1 = ["Cecilie", "Lone"];
  const array2 = ["Emil", "Tobias", "Linus"];
  const array3 = ["Robin", "Morgan"];
  const myChildren = array1.concat(array2, array3);
  document.getElementById("demo").innerHTML = myChildren;
</script>
</body>
<!-- /js/tryit.asp?filename=tryjs_array_concat2  Thu, 06 Feb 2025 18:00:45 GMT -->
</html>