Learn Introductory JavaScript by Building a Pyramid Generator - Step 38

Tell us what’s happening:

I am a little confused about what I should put in the () because the hint says:

You should call .push() on your rows array.

But I thought that was what I had done. Any help will be fantastic :smile:

Your code so far

const character = "#";
const count = 8;
const rows = [];


// User Editable Region

for (let i = 0; i < count; i = i + 1) {
  array.push(rows);
}

// User Editable Region

Your browser information:

User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/132.0.0.0 Safari/537.36

Challenge Information:

Learn Introductory JavaScript by Building a Pyramid Generator - Step 38

array.push(rows);

rows is the array

1 Like

Hi there. You need to push i in the rows. Currently you are pushing rows in the array

1 Like

You guys both had the right fix. Thank you so much!!