Learn Introductory JavaScript by Building a Pyramid Generator - Step 21

Tell us what’s happening:

My code is True!!! wo ist den Fehler?
let rows = [“Naomi”, “Quincy”, “CamperChan”];
console.log(rows);
rows[2] = 10;
console.log(rows);

/ Tests werden durchgeführt
You should use bracket notation on the rows array again.
// Tests abgeschlossen
// Konsolen-Ausgabe
[ ‘Naomi’, ‘Quincy’, ‘CamperChan’ ]
[ ‘Naomi’, ‘Quincy’, 10 ]

Your code so far

let character = 'Hello';
let count = 8;

// User Editable Region

let rows = ["Naomi", "Quincy", "CamperChan"];
console.log(rows);
rows[2] = 10;
console.log(rows);


// User Editable Region

Your browser information:

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

Challenge Information:

Learn Introductory JavaScript by Building a Pyramid Generator - Step 21

Hello,
you redeclared the rows variable and your code has three console.log not two as stated by the errors, remove the first two lines in the User Editable Region

1 Like