Learn Introductory JavaScript by Building a Pyramid Generator - Step 11

Tell us what’s happening:

I don’t understand what I’m missing here. I’m reassigning the “Character” value to the “secondCharacter” value. My code look like this.
let secondCharacter = “Hello”;
let Character = “World”;
secondCharacter = Character;
What am I missing?

Your code so far

let character = 'Hello';
console.log(character);
character = "World";

// User Editable Region

let secondCharacter = "Hello";
let Character = "World";
secondCharacter = Character;

// User Editable Region

console.log(secondCharacter);

Your browser information:

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

Challenge Information:

Learn Introductory JavaScript by Building a Pyramid Generator - Step 11

Hi there!

Declaring Character is not asked in the challenge instructions.

1 Like

Hi there and welcome to our community!

This is the line of code which you start this step with:

secondCharacter = "Test";

You should not add any other lines of code. Simply modify the line above to reassign it as per the instructions.

1 Like

Welcome to the forum @Legless_Rage_11

You declared the character variable with the let keyword on line one.
You can only declare variables once this way.

Also, Character and character are two different variables, as variable naming in JavaScript is case sensitive.

As @hasanzaib1389 pointed out you are not asked to declare the Character variable.

Please follow the advise of @igorgetmeabrain and modify the assignment of the variable.

Happy coding

1 Like