Giving error every time

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

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

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

let result = "";

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

console.log(result);

If you have a question about a specific challenge as it relates to your written code for that challenge and need some help, click the Help button located on the challenge (it looks like a question mark). This button only appears if you have tried to submit an answer at least three times.

The Help button will create a new topic with all code you have written and include a link to the challenge also. You will still be able to ask any questions in the post before submitting it to the forum.

Thank you.

my code is not passing
i have used the repeat method but still not passing.
You should use the

.repeat()

method. You should use the

.repeat()

method on your

character

variable. You should return the result of your

.repeat()

call.

Post link to the challenge step.