+ 3
How to calculate length?
<script> var num1= [1,2]; var num2=[3,4]; var set=num1+ num2 ; document.write(set.length); </script>
4 odpowiedzi
+ 1
num1.push(num2)
+ 1
You mean the length or the result
+ 1
Both
0
If you want Merge two array you must define array in first , for your case you must define
var set =new Array(4);
Now you allocated
Then you must using for loop to put num1 and num2 to empty Array set