Tell us what’s happening:
Describe your issue in detail here.
Your code so far
// Setup
const myArray = [["John", 23], ["dog", 3]];
const removedFromOurArray = myArray.shift();
// Only change code below this line
Your browser information:
User Agent is: Mozilla/5.0 (X11; CrOS aarch64 14816.131.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/103.0.0.0 Safari/537.36
Challenge: Basic JavaScript - Manipulate Arrays With shift()
Link to the challenge:
Hello there.
Do you have a question?
If so, please edit your post to include it in the Tell us what’s happening section.
Learning to describe problems is hard, but it is an important part of learning how to code.
Also, the more information you give us, the more likely we are to be able to help.
Use the .shift()
function to remove the first item from myArray
and assign the “shifted off” value to a new variable, removedFromMyArray
.
You did not use the required variable name
system
Closed
3
This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.