Learn Introductory JavaScript by Building a Pyramid Generator - Step 28

Tell us what’s happening:

My code is not working and i have googled and it is still not working pls can i have some help it is annoying me

Your code so far

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

// User Editable Region

for () {
    console.log(`Iteration ${iterator}`);

// 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/ Safari/537.36

Challenge Information:

Learn Introductory JavaScript by Building a Pyramid Generator - Step 28

construct a for loop that includes the terms "iterator", "condition", and "iteration" for the three components.

You are supposed to do it between the parenthesis:

I have tried that but it is not working

You need to use strings ("iterator" instead of iterator and so on).

you forget to add qoutes around.

it has fixed that but i am stuck on another error

that’s a syntax error, remember that JavaScript needs many parenthesis. Also do not use print, you are going to try to connect to your printer

do not put your own thoughts in the challenge code editor while you are doing the curriculum challages steps. just follow the instructions.

can i have some help to fix it pls

first you need to post your code here as preformatted text using → </> option and copy paste your code between a pair of back tiks, instead of screenshot.

3 | const rows = ;
4 |

5 | for (let i = 0; ( i <count);
| ^

SyntaxError: unknown: Unexpected token (5:28)

you have tried this before, you had missed only to add qoute marks around itiritaion, codition and itirator.

this is different from what i was doind before

i do not know. above is your own screenshot.

i have this error You should log the value of


in your



show your code. Is this still for step 28?

no it is step 32 now but here is my code const character = “#”; // The character to repeat
const count = 8; // The number of times to repeat the character
const rows = ; // The array to store the repeated characters

// Create a for loop to iterate ‘count’ times
for (let i = 0; i < count; i++) {
console.log(i); // Log the current value of i
rows.push(character); // Add the character to the array