Basic JavaScript - Access Multi-Dimensional Arrays With Indexes

Tell us what’s happening:
Describe your issue in detail here.
Need help to get pass this topic. Can’t find the solution. Please advise. Thanks

  **Your code so far**
const myArray = [
[1, 2, 3],
[4, 5, 6],
[7, 8, 9],
[[10, 11, 12], 13, 14],
];

const myData = myArray[2][2];
  **Your browser information:**

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

Challenge: Basic JavaScript - Access Multi-Dimensional Arrays With Indexes

Link to the challenge:

There is an issue with your counting, one of you indices is wrong. Hint: Remember that computers start counting with 0, not 1.

As a helper, remember that you can put

console.log(myData);

at the bottom of the code to see what cell you are targeting. It will show up in the console window below.

thank you sir. managed to solve it :slight_smile:

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.