Back to Code Walkthrough
Shrinking an Array with length
JavaScript code walkthrough · Question 50Code
Read carefully. What does this print?1let a = [1, 2, 3, 4, 5];2a.length = 3;3a.push(9);4console.log(a.join("-"));5console.log(a.length);