Just learned about 2D arrays, however unless ive missed something, i haven't been taught how to call up the data from within the array. In the example code below, i want to console.log the number 5. The console.log underneath was my attempt at doing so, however i get 'undefined' instead of the number. Can anyone explain this to me? I really dont want to move on until i understand this.
var jagged = [[1,2,3], [4,5], 6] console.log (jagged[1])