What I am doing wrong here? I am getting TypeError: items[i] is undefined as the error.
var items = [];
for(var i = 1; i <= 3; i++){
items[i].push('a', 'b', 'c');
}
console.log(items);
I need an output as given below,
[
['a', 'b', 'c'],
['a', 'b', 'c'],
['a', 'b', 'c']
]