Basic JavaScript - Manipulate Arrays With push Method

Tell us what’s happening:
whats the issue?

Your code so far

// Setup
const myArray = [["John", 23], ["cat", 2]];

// Only change code below this line
myArray.push = (["dog", 3]);


Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/116.0.0.0 Safari/537.36

Challenge: Basic JavaScript - Manipulate Arrays With push Method

Link to the challenge:

The syntax here is not quite right.

I would suggest looking again at the sample code they gave you so you can compare the syntax to your answer

arr2.push(["happy", "joy"]);
1 Like

only remove the = sign