Learn Introductory JavaScript by Building a Pyramid Generator - Step 66

Tell us what’s happening:

I am not sure what I am doing wrong with this code. Here is what I have so far:
for (let i = 0; i < count; i = i + 1) {
rows.push(padRow)
}

Your code so far

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

function padRow(rowNumber, rowCount) {
  return character.repeat(rowNumber);
}



// User Editable Region

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

// User Editable Region


let result = ""

for (const row of rows) {
  result = result + row + "\n";
}

console.log(result);

Your browser information:

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

Challenge Information:

Learn Introductory JavaScript by Building a Pyramid Generator - Step 66

you still need to call padRow as the request was

Replace the character.repeat(i + 1) in your .push() call with a function call for your padRow function.

I am calling a padRow call in my .push() call. Maybe I need to call it a different way?

you are not calling the function, you have only written the name of the function there, that is not enough to call the function

More like this?
rows.push(padRow(character, i + 1));

more like that, but you are asked to not pass any arguments for now

Well im at a complete loss here. I have this and its not working.
rows.push(padRow)
I don’t know what else to do. I have read and reread the directions 100 times. Not helping. Sadly this program won’t allow me to move forward… May have to leave this camp and find one that shows solutions when stuck while im learning

here the function is not being called, that’s the issue

if this is the function call, which part are the arguments that you need to remove?

Ok im gonna go with this:
rows.push(padRow());

that’s good! you are pushing a call to padRow there!

Thank you for the help this one worked!