Learn Introductory JavaScript by Building a Pyramid Generator - Step 37

Tell us what’s happening:

I have no idea what I am supposed to put into the curly brackets. I have stared at this question for quite a while now, but I am completely stuck

Your code so far

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


// User Editable Region

for (let i = 0; i < count; i = i + 1) {

}


// User Editable Region

Your browser information:

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

Challenge Information:

Learn Introductory JavaScript by Building a Pyramid Generator - Step 37

you need to print i to the console, do you remember how to
print things to the console?

console.log(i) correct?

you can try, let me know how it goes

Still wrong. I guess I’ll just go back a few lessons. I really don’t understand what it’s asking here

post your latest code

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

it looks like you added more than just the code to print i, why is that?

I am not sure, when I went back a few steps and got to 37 again, rows.push was in there. I’m still completely and utterly lost, but now it is showing 0-7 in the console

Hi there!
May be you added row.push() to your challenge step early and when you reached that step again, you found early added code there. Reset your challenge step and try again.

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